Detects all in-scope variables.
In practice this means iterating through the entire algebra tree, finding all variables,
and stopping when a project function is found.
Param: op
Input algebra tree.
Param: visitor
the visitor to be used to traverse the various nodes.
Allows you to provide a visitor with different default preVisitor cotexts.
Detects all in-scope variables. In practice this means iterating through the entire algebra tree, finding all variables, and stopping when a project function is found.