Hacker News new | past | comments | ask | show | jobs | submit login

I get the reasoning behind it, but the choice of the division operator is still a little weird.

I believe it should be equally possible to overload the bitwise OR operator (|), which, for people used to piping in Unix, is probably more intuitive.




Wrong direction: you‘d „pipe“ wat through the object. Although TiddlyWiki users might feel right at home.


Right, that would be a wrong pipe direction. Fun fact: It's already possible to do "wat | foo" or "wat << foo" (if you're more familiar with C++ iostream), it has the same effect as "wat / foo"


It could override the reverse bitwise or magic method `__ror__`.




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

Search: