Skip to content
refractalize edited this page Apr 26, 2012 · 1 revision

I'm not especially happy with the current crop of JavaScript-esque operators. Especially && and || and !. I think Ruby's and, or and not are much more elegant. But how do we fit them into PogoScript? After all, any word that appears in a form is taken to be part of the name of a function or variable.

This won't work as it does in Ruby:

a and b

Because variables can contain spaces:

show details and has access

Instead operators work, which can't be part of identifiers:

show details && has access

But we should try something else, named operators, not-unlike Haskell's infix operator:

show details @and has access

Of course we can try a number of symbols to get it right:

show details %and has access

show details $and has access

show details #and has access
Clone this wiki locally