Hi,

I think this is a technical misunderstanding. It's true that "unless" 
usually is the same as "if not", but that does not mean you can 
literally replace every "if not" with "unless". It's not a macro. The 
Ruby parser treats "unless" as a keyword on it's own with special rules 
where it can occur and how those structures are evaluated.

So when you talk about "unexpected behaviour", this is rather a problem 
of you having the wrong expectations. Saying that one thing means the 
same as another does usually *not* mean they're actually interchangeable 
on syntax level.

-- 
Posted via http://www.ruby-forum.com/.