Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

So you want it to compile to POSIX sh but you're unhappy it doesn't use more POSIX-incompatible features? Maybe full POSIX sh compat is WIP, or in some simpler cases maybe it already is?


Retr0id, not sgarland want posix.

> Maybe full POSIX sh compat is WIP

Still - I sure hope it's possible to do a comparison in sh without spawning two processes.


As I've just updated my comment to reflect, TIL that parameter substitution is supported (with some exceptions) by `sh`.

More broadly though, yes, there's a tendency for people to pop sub-shells without giving it a second thought. Those aren't free; use shell built-ins whenever possible!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: