|flex default rule firstname.lastname@example.org (Dimitri Maziuk) (2006-04-01)|
|Re: flex default rule email@example.com (John Millaway) (2006-04-03)|
|Re: flex default rule firstname.lastname@example.org (Dimitri Maziuk) (2006-04-03)|
|Re: flex default rule email@example.com (Chris Dodd) (2006-04-03)|
|Re: flex default rule firstname.lastname@example.org (Dimitri Maziuk) (2006-04-08)|
|From:||Dimitri Maziuk <email@example.com>|
|Date:||8 Apr 2006 17:09:31 -0400|
|Posted-Date:||08 Apr 2006 17:09:31 EDT|
Dimitri Maziuk sez:
> Dimitri Maziuk sez:
>> Hi all,
>> here's what I can't quite figure out:
> Scratch that. I've been staring at my screen too long.
> This is a backport from Java, and JFlex has a couple of differences
> from flex. Most importantly, when more than one rule matches, JFlex
> will apply the first rule in the set whereas flex applies the longest
> matching one.
Or, rather, JFlex has a "[^]" that's equivalent to ".|\n" -- I initially
replaced it with "." in flex specs and it stopped matching tokens with
newlines it 'em. Surprise, surprise.
There was a braino in my OP, too: the 3rd rule was supposed to be in
<SEMI>, not <INITIAL>.
Double d = new Double(2.0);
d = new Double(d.doubleValue() * d.doubleValue());
I regard Double variables as mutable, considering this one started as 2.0 and
ended up as 4.0. -- Brendan Guild
Return to the
Search the comp.compilers archives again.