Hacker News new | ask | show | jobs
by walrus 5099 days ago
How about both?

  Udon.flip = function(f) {
      return function(x) {
          if(arguments.length > 1) {
              return f(arguments[1])(x);
          }
          return function(y) {
              return f(y)(x);
          };
      };
  };