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

It’s a horizontal pipe. It arguably actually makes more sense when the values flow horizontally from left to right through the pipe.

In an alternative universe, Unix shell syntax may have used “—“ instead of “|” for piping.



PS: The commands in Unix pipes are executed in parallel, and “|” could be interpreted as a mnemonic of that fact. However, the same is not true for the programming-language feature discussed here, which only processes singular values, not streams.




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

Search: