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

I don't think that it's a good idea to introduce a left-to-right flow into a language, which strictly assigns righthand values by general design. The text mentions a back-and-forth in reading, this introduces a back-and-forth intellectually.

(There's already a limited left to right capability, namely by chaining expressions using logical operators, especially when used outside of condition. It should be mentioned, however, that this is already confusing to some.)




  !(funcA(transferObject) || true) || !(funcB(transferObject) || true) ...
  // ceci n'est pas une pipe

  function pipe(func, obj) {
    return !(func(obj) || true);
  }
  pipe(funcA, transferObject) || pipe(funcB, transferObject) ...
  // cecie n'est pas une pipe non plus

  function pipeB(func, obj) {
    func(obj);
    return 0 | 0;
  }
  pipeB(funcA, transferObject) | pipeB(funcB, transferObject) ...
  // no more pipes, please!
 
  funcA(transferObject), funcB(transferObject) ...
  // finally...
;-)




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

Search: