You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A new 'with' statement provides syntactic sugar for monadic control flow.
Within a block, the subsequent statements after a 'with' statement are
passed as a capture-by-value lambda to the function specified as the 'with'
statement's operand.
// 0.2
foo(x) {
with y = bar(x);
with z = bas(y);
qux(z);
}
A new 'with' statement provides syntactic sugar for monadic control flow.
Within a block, the subsequent statements after a 'with' statement are
passed as a capture-by-value lambda to the function specified as the 'with'
statement's operand.
// 0.2
foo(x) {
with y = bar(x);
with z = bas(y);
qux(z);
}
// desugars to
foo(x) {
bar(y => {
bas(z => {
qux(z);
}, y);
}, x);
}
Thanks to Arvid Picciani.