* Applies a few default rules for adding operands to expressions. In particular wraps
* all lists into LIST expressions. Applied only in path expressions.
*/
protected static Object wrapPathOperand(Object op) {
if (op instanceof Collection) {
return new ASTList((Collection<?>) op);
}
else if (op instanceof Object[]) {
return new ASTList((Object[]) op);
}
else {
return op;
}
}