Nice/src/bossa/parser Parser.jj,1.313,1.314
Arjan Boeijink <[email protected]>
| Newsgroups | gmane.comp.lang.nice.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/nice/Nice/src/bossa/parser
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4762/F:/nice/src/bossa/parser
Modified Files:
Parser.jj
Log Message:
Implemented instanceof on option types.
Index: Parser.jj
===================================================================
RCS file: /cvsroot/nice/Nice/src/bossa/parser/Parser.jj,v
retrieving revision 1.313
retrieving revision 1.314
diff -C2 -d -r1.313 -r1.314
*** Parser.jj 8 Mar 2005 19:12:13 -0000 1.313
--- Parser.jj 9 Mar 2005 14:47:46 -0000 1.314
***************
*** 2067,2073 ****
{
res=RelationalExpression()
! [ { Token t; TypeConstantExp type; }
! t="instanceof" type=typeExpression()
! { type.isLiteral = true; return bossa.syntax.dispatch.createCallExp(symb(t), res, type); }
]
{ return res; }
--- 2067,2081 ----
{
res=RelationalExpression()
! [ { Token t; TypeConstantExp type; boolean option = false;}
! t="instanceof"
! [ "?" {option = true;} ]
! type=typeExpression()
! { type.isLiteral = true;
! Expression sym;
! if (option)
! sym = symb("optionInstanceof", t, true);
! else
! sym = symb(t);
! return bossa.syntax.dispatch.createCallExp(symb(t), res, type); }
]
{ return res; }
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click