Changeset 6a1dfda for src/Parser


Ignore:
Timestamp:
Jun 13, 2019, 8:41:11 PM (5 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
c36298d
Parents:
dc5072f (diff), 6896548 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Peter A. Buhr <pabuhr@…> (06/13/19 20:39:34)
git-committer:
Peter A. Buhr <pabuhr@…> (06/13/19 20:41:11)
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/ExpressionNode.cc

    rdc5072f r6a1dfda  
    354354                strtype = new BasicType( Type::Qualifiers( Type::Const ), BasicType::Char );
    355355        } // switch
    356         ArrayType * at = new ArrayType( noQualifiers, strtype,
    357                                                                         new ConstantExpr( Constant::from_ulong( str.size() + 1 - 2 ) ), // +1 for '\0' and -2 for '"'
    358                                                                         false, false );
    359         Expression * ret = new ConstantExpr( Constant( at, str, (unsigned long long int)0 ) ); // constant 0 is ignored for pure string value
     356        Expression * ret = new ConstantExpr( Constant::from_string( str, strtype ) );
    360357        if ( units.length() != 0 ) {
    361358                ret = new UntypedExpr( new NameExpr( units ), { ret } );
Note: See TracChangeset for help on using the changeset viewer.