let a = [ 1; 2; 3; if 3 > 2 then 4; else 5; 6 ]
What fails with "this construct corrupts ...... Paranthesize is an expression to indicate that it is a separate list item ..." what I do is
let a = [ 1; 2; 3; (if 3 > 2 then 4 else 5); 6 ]
makes the compiler tell me "unsurpassed" ("". Obviously, the compiler does not like conditional binding with binding to a multi-line line. Why is this? And is there any way?
This is a trivial case, but in actual use I will have arbitrarily complex recursive expressions (so I need to break it into several lines), and I do not want to decompose this expression and do it strictly through list-appending and what not.
EDIT: this works:
let a = [ 1; 2; 3; if 3 > 2 then yield( 4 )else yield( 5); 6 ]
but somewhat more verbose than I would prefer (5 keywords and 4 brackets for a simple triple operation!). The search for something cleaner continues
source share