Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/ExpressionNode.cc

    r5809461 rba2a68b  
    1010// Created On       : Sat May 16 13:17:07 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Fri Sep  1 15:07:09 2017
    13 // Update Count     : 618
     12// Last Modified On : Fri Sep  1 21:49:16 2017
     13// Update Count     : 622
    1414//
    1515
     
    6666} // sepNumeric
    6767
    68 Expression * build_constantInteger( std::string & str ) {
     68Expression * build_constantInteger( string & str ) {
    6969        static const BasicType::Kind kind[2][3] = {
    7070                { BasicType::SignedInt, BasicType::LongSignedInt, BasicType::LongLongSignedInt },
     
    148148  CLEANUP:
    149149        if ( units.length() != 0 ) {
    150                 ret = new UntypedExpr( new NameExpr( units, ret ) );
     150                ret = new UntypedExpr( new NameExpr( units ), { ret } );
    151151        } // if
    152152
     
    190190        Expression * ret = new ConstantExpr( Constant( new BasicType( noQualifiers, kind[complx][size] ), str, v ) );
    191191        if ( units.length() != 0 ) {
    192                 ret = new UntypedExpr( new NameExpr( units, ret ) );
     192                ret = new UntypedExpr( new NameExpr( units ), { ret } );
    193193        } // if
    194194
     
    211211        Expression * ret = new ConstantExpr( Constant( new BasicType( noQualifiers, BasicType::Char ), str, (unsigned long long int)(unsigned char)str[1] ) );
    212212        if ( units.length() != 0 ) {
    213                 ret = new UntypedExpr( new NameExpr( units, ret ) );
     213                ret = new UntypedExpr( new NameExpr( units ), { ret } );
    214214        } // if
    215215
     
    228228// ROB: type mismatch
    229229        // if ( units.length() != 0 ) {
    230         //      ret = new UntypedExpr( new NameExpr( units, ret ) );
     230        //      ret = new UntypedExpr( new NameExpr( units ), { ret } );
    231231        // } // if
    232 
     232               
    233233        delete &str;                                                                            // created by lex
    234234        return ret;
     
    282282} // build_varref
    283283
    284 // TODO: get rid of this and OperKinds and reuse code from OperatorTable
     284
    285285static const char * OperName[] = {                                              // must harmonize with OperKinds
    286286        // diadic
     
    290290        "?[?]", "...",
    291291        // monadic
    292         "+?", "-?", "AddressOf", "*?", "!?", "~?", "++?", "?++", "--?", "?--",
     292        "+?", "-?", "AddressOf", "*?", "!?", "~?", "++?", "?++", "--?", "?--", "&&"
    293293}; // OperName
    294294
Note: See TracChangeset for help on using the changeset viewer.