Bill Steer wrote:
> Please excuse this newbie question. I'm generating a lexer/parser in
> C#, setting the 'language' option to 'Csharp2'. It's successfully
> generating the code, but there are several errors in it, as follows:
>
> 1. It's missing a ';' on one statement.
> 2. It's missing a cast from IList to ArrayList on one statement.
> 3. I haven't found a way to include a 'namespace' statement in the
> generated code.
>
> Are these common errors, or is there a way around them?
>
> Thanks for any help.
>
> Bill Steer
>
>
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe:
> http://www.antlr.org/mailman/options/antlr-interest/your-email-address
>
To add a namespace, use:
@namespace { namespace1 }
Which should be placed after any tokens {} section (before your first rule).
For the other two, make sure you are using the latest tool to generate
the code and see if gives anything different, but you probably need to
post your grammar for the C# guys to take a look at.
Jim
List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe:
http://www.antlr.org/mailman/options/antlr-interest/your-email-address
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"il-antlr-interest" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/il-antlr-interest?hl=en
-~----------~----~----~----~------~----~------~--~---