LogicalUtil defines a bunch of overloaded methods that help dispatch
data form construction based on runtime class of logical variable.
This eliminates the need to use coerce in generator template.
LogicalVariableDataForm generates to either a list node or a term.
This choice can be made based on the structure alone.
Logical variable "array" corresponds to list node, everything else to a term.
Usually one uses Splice with LogicalItemExpression wrapping a logical variable.
Using LogicalDataForm wrapping same variable makes Splice unnecessary.
In order to keep code readable these are wrapped again in a cons list.
In general, one should avoid using bare LogicalDataForm, as these are
indistiguishable from normal LogicalVariable.
requiredHash of a rule now includes hashes not only of SNode & SNodeRef
but also of anything except Coderules rt types (e.g. MetaLogical & DataForm).
The motivation is that if something else is used -- then it must come
from AST, so the rule must be regenerated on any changes to that data.
requiredHash is renamed to usedDataHash to reflect that fact.
In particular, fixes dependence of IndexedTupleAccess rule on idx
from `idx = tuple.index.getCompileTimeConstant()`.
Expand macro supports dispatching by concept.
Logical variables declared on macro's body are init'ed in apply method.
Enable the hack to ensure dependencies on macro input are tracked.
Macro table can extend another macro table. All prototype template
declarations are imported automatically.
The editor now substitutes default values when entering new
expand macro/constraint filling the slots provided by the prototype.
Expand macro does not require name.
Minor editor improvements.
Expand macro template must have declaration of logicals matching
exactly the logical declarations in the prototype.
Can't refer to logicals declared directly in the prototype.
Parameters can be specified for call macro only.
Logicals can be specified for expand and call macro.
Expand macro params are treated exactly as "context"
parameters.
The old expand/call constructs are to be replaced by these.
Expand macro constraint refers to a named prototype, which
is specified in a macro table for matching concept.
Call macro constraint refers directly to a macro template.
Contex parameters are to be retired and explicit
parameters to expand macro constraint are to be used instead.