Ignore:
Timestamp:
Dec 3, 2014, 3:08:38 PM (9 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
Children:
d9a0e76
Parents:
42dcae7
Message:

underscore changes, ptrdiff_t changes, formating, _Bool prelude

File:
1 edited

Legend:

Unmodified
Added
Removed
  • translator/Parser/cfa.y

    r42dcae7 r3848e0e  
    1010 * Created On       : Sat Sep  1 20:22:55 2001
    1111 * Last Modified By : Peter A. Buhr
    12  * Last Modified On : Sun Nov  9 22:45:42 2014
    13  * Update Count     : 881
     12 * Last Modified On : Tue Nov 25 23:52:54 2014
     13 * Update Count     : 890
    1414 */
    1515
     
    563563        | tuple assignment_opt                          /* CFA, tuple expression */
    564564                {
    565                   if( $2 == 0 ) {
     565                  if ( $2 == 0 ) {
    566566                    $$ = $1;
    567567                  } else {
     
    654654        block_item
    655655        | block_item_list push block_item
    656                 { if($1 != 0) { $1->set_link($3); $$ = $1; } }
     656                { if ($1 != 0) { $1->set_link($3); $$ = $1; } }
    657657        ;
    658658
     
    668668        statement
    669669        | statement_list statement
    670                 { if($1 != 0) { $1->set_link($2); $$ = $1; } }
     670                { if ($1 != 0) { $1->set_link($2); $$ = $1; } }
    671671        ;
    672672
     
    18701870        | external_definition_list
    18711871                {
    1872                   if( theTree ) {
     1872                  if ( theTree ) {
    18731873                    theTree->appendList( $1 );
    18741874                  } else {
     
    18821882        | external_definition_list push external_definition
    18831883                {
    1884                   if( $1 ) {
     1884                  if ( $1 ) {
    18851885                    $$ = $1->appendList( $3 );
    18861886                  } else {
     
    27322732/* ----end of grammar----*/
    27332733
    2734 void yyerror(char *string) {
     2734void yyerror( char *string ) {
    27352735    using std::cout;
    27362736    using std::endl;
    2737     if( yyfilename ) {
    2738       cout << yyfilename << ":" << endl;
     2737    cout << "Error ";
     2738    if ( yyfilename ) {
     2739        cout << "in file " << yyfilename << " ";
    27392740    }
    2740     cout << yylineno << ": syntax error reading token " << *(yylval.tok.str) << endl;
     2741    cout << "at line " << yylineno << " reading token \"" << *(yylval.tok.str) << "\"" << endl;
    27412742}
    27422743
Note: See TracChangeset for help on using the changeset viewer.