The 'expressionize' function seems to be at the core of implicit returns. It seems to be a promising approach to morphing Javascript into an everything-is-an-expression language. Unfortunately right now it is poorly documented and not used everywhere it could be. Hopefully we can discuss where this feature is heading publicly and finish up expressionizing parenscript.
Right now LET does not seem to take advantage of expressionize the same way functions do. LET fails to turn TRY into an expression, while implicit return works. What would we need to do to add this?
(ps:ps (let ((x (ps:try xxx (:catch (x) 5)))) x)) "var x233 = try { xxx; } catch (x) { 5; }; x233;"
below works:
(ps:ps (lambda ()
(ps:try xxx (:catch (x) 5)))) "function () { try { return xxx; } catch (x) { return 5; }; };"
Thanks for the insights, Red