oils-for-unix / oils

Oils is our upgrade path from bash to a better language and runtime. It's also for Python and JavaScript users who avoid shell!
http://www.oilshell.org/
Other
2.85k stars 159 forks source link

executing blocks that contain return/break/continue/error is inconsistent with eval on strings #2039

Open andychu opened 3 months ago

andychu commented 3 months ago

This is

Shell already has this issue with eval and processes

And then YSH adds blocks / eval ()


Based on feedback from Julian

https://oilshell.zulipchat.com/#narrow/stream/384942-language-design/topic/Return.20within.20context.20.28cd.20.7B.20.7D.2C.20.2E.2E.2E.29

andychu commented 2 months ago

@jtb20 - I made eval (block) consistent with eval $mystr -- this will be out with Oils 0.24.0