Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/lex.ll

    r8b47e50 r4e9c7c1  
    1010 * Created On       : Sat Sep 22 08:58:10 2001
    1111 * Last Modified By : Peter A. Buhr
    12  * Last Modified On : Wed Jul 12 18:04:44 2017
    13  * Update Count     : 535
     12 * Last Modified On : Thu Jul 27 21:46:06 2017
     13 * Update Count     : 550
    1414 */
    1515
    1616%option yylineno
     17%option noyywrap
    1718%option nounput
    1819
     
    125126op_unary {op_unary_only}|{op_unary_binary}|{op_unary_pre_post}
    126127
    127 op_binary_only "/"|"%"|"^"|"&"|"|"|"<"|">"|"="|"=="|"!="|"<<"|">>"|"<="|">="|"+="|"-="|"*="|"/="|"%="|"&="|"|="|"^="|"<<="|">>="
     128op_binary_only "/"|"%"|"\\"|"^"|"&"|"|"|"<"|">"|"="|"=="|"!="|"<<"|">>"|"<="|">="|"+="|"-="|"*="|"/="|"%="|"\\="|"&="|"|="|"^="|"<<="|">>="
    128129op_binary_over {op_unary_binary}|{op_binary_only}
    129130                                // op_binary_not_over "?"|"->"|"."|"&&"|"||"|"@="
     
    136137
    137138%%
    138                                    /* line directives */
     139                                /* line directives */
    139140^{h_white}*"#"{h_white}*[0-9]+{h_white}*["][^"\n]+["].*"\n" {
    140141        /* " stop highlighting */
     
    232233int                             { KEYWORD_RETURN(INT); }
    233234__int128                { KEYWORD_RETURN(INT); }                                // GCC
     235__int128_t              { KEYWORD_RETURN(INT); }                                // GCC
    234236__label__               { KEYWORD_RETURN(LABEL); }                              // GCC
    235237long                    { KEYWORD_RETURN(LONG); }
     
    266268__typeof                { KEYWORD_RETURN(TYPEOF); }                             // GCC
    267269__typeof__              { KEYWORD_RETURN(TYPEOF); }                             // GCC
     270__uint128_t             { KEYWORD_RETURN(INT); }                                // GCC
    268271union                   { KEYWORD_RETURN(UNION); }
    269272unsigned                { KEYWORD_RETURN(UNSIGNED); }
    270273__builtin_va_list { KEYWORD_RETURN(VALIST); }                   // GCC
     274virtual                 { KEYWORD_RETURN(VIRTUAL); }                    // CFA
    271275void                    { KEYWORD_RETURN(VOID); }
    272276volatile                { KEYWORD_RETURN(VOLATILE); }
     
    285289
    286290                                /* numeric constants */
    287 "0"                             { NUMERIC_RETURN(ZERO); }                               // CFA
    288 "1"                             { NUMERIC_RETURN(ONE); }                                // CFA
    289291{decimal_constant} { NUMERIC_RETURN(INTEGERconstant); }
    290292{octal_constant} { NUMERIC_RETURN(INTEGERconstant); }
     
    337339"-"                             { ASCIIOP_RETURN(); }
    338340"*"                             { ASCIIOP_RETURN(); }
     341"\\"                    { ASCIIOP_RETURN(); }                                   // CFA, exponentiation
    339342"/"                             { ASCIIOP_RETURN(); }
    340343"%"                             { ASCIIOP_RETURN(); }
     
    361364"+="                    { NAMEDOP_RETURN(PLUSassign); }
    362365"-="                    { NAMEDOP_RETURN(MINUSassign); }
     366"\\="                   { NAMEDOP_RETURN(EXPassign); }                  // CFA, exponentiation
    363367"*="                    { NAMEDOP_RETURN(MULTassign); }
    364368"/="                    { NAMEDOP_RETURN(DIVassign); }
     
    415419
    416420                                /* unknown characters */
    417 .                       { printf("unknown character(s):\"%s\" on line %d\n", yytext, yylineno); }
     421.                               { printf("unknown character(s):\"%s\" on line %d\n", yytext, yylineno); }
    418422
    419423%%
Note: See TracChangeset for help on using the changeset viewer.