Re-worked Expression Parser
Displaying 1-1 of 1 total.
1
Please enter a numerical value for the importance of this sticky.
Enter 0 to unsticky.
Jesse

Hey all,

I've just checked in a re-organized expression parser that unifies conditional and normal expressions. Rather than trying to explain it in works, it basically means that this now works:

int x = (1 < 2 && 3 >= 4) || 12 - 11;
if(x && (!2 || strcmp('hi', 'yo') == 0)) {
//...
}


One problem with this is that verge is still treating = and == as the same, so the following:

int y = x = z;


really means

int y := (x == z);


which is probably not what you meant. I think that's the only gotcha for now. Let me know if you find any code that used to work that doesn't now.

Posted on 2005-06-30 12:12:37


Displaying 1-1 of 1 total.
1
 
Newest messages

Ben McGraw's lovingly crafted this website from scratch for years.
It's a lot prettier this go around because of Jon Wofford.
Verge-rpg.com is a member of the lunarnet irc network, and would like to take this opportunity to remind you that regardless how babies taste, it is wrong to eat them.