Issue: We have asked JLink to convert things into Expr via the Loopback Link where we could well have done it ourselves. It seems wasteful, and is perhaps clearer when we do it ourselves. This applies especially to primitive types (numbers, String) and cases where we ended up with a list of Expr that wasn't a function call.
Fix: 1. Extend proto/expr with non-seq input to simply pass it on to new Expr, so that anything it supports will be expressionified. Cons: we fall back on reflection here (though we could explicitly check the type and cast to it, but what's the pro?). 2. if every sub-part of a list an Expr, construct manually a Wolf List.
Bonus: Added support for passing in primitive Java arrays of numbers (so far only 1D).
Risk: All tests pass, but this changes how we convert from Clj to Expr, and it may have changed something I am unaware of.
Issue: We have asked JLink to convert things into Expr via the Loopback Link where we could well have done it ourselves. It seems wasteful, and is perhaps clearer when we do it ourselves. This applies especially to primitive types (numbers, String) and cases where we ended up with a list of Expr that wasn't a function call.
Fix: 1. Extend
proto/expr
with non-seq input to simply pass it on tonew Expr
, so that anything it supports will be expressionified. Cons: we fall back on reflection here (though we could explicitly check the type and cast to it, but what's the pro?). 2. if every sub-part of a list an Expr, construct manually a Wolf List.Bonus: Added support for passing in primitive Java arrays of numbers (so far only 1D).
Risk: All tests pass, but this changes how we convert from Clj to Expr, and it may have changed something I am unaware of.