options { IGNORE_CASE=false; } PARSER_BEGIN(HL) public class HL { } PARSER_END(HL) TOKEN_MGR_DECLS : { static int depth; } SKIP : { " " | "\t" | "\n" | "\r" | <"//" (~["\n","\r"])* ("\n" | "\r" | "\r\n")> | "/'" { depth = 1; SwitchTo(COMMENT_BLOCK); } } SKIP: { < "/'" > { depth++; } | < "'/" > { if (--depth == 0) SwitchTo(DEFAULT); } | < ~[] > } TOKEN : { | | | | | | | | | | | | | | | | "> | ="> | | | | | | | | | | | | | | | | | | | | | | | | | | }