Why does this throw a syntax error? I would expect it to be the other way around...
>> foo = 5 >> foo = foo++ + ++foo
Ruby does not have a ++operator. In your example it just adds the second foo, "consuming" one plus, and treats the other ones as unary + operators.