ngs-lang / ngs

Next Generation Shell (NGS)
https://ngs-lang.org/
GNU General Public License v3.0
1.4k stars 43 forks source link

Consider adding try() method #541

Closed ilyash-b closed 2 years ago

ilyash-b commented 2 years ago

Based on https://guides.rubyonrails.org/active_support_core_extensions.html#try

ilyash-b commented 2 years ago

Would roughly be:

F try(x, f:Fun) f(x)
F try(n:Null, f:Fun) n