Ignore:
Timestamp:
Sep 21, 2022, 10:52:51 AM (20 months ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, ast-experimental, master, pthread-emulation
Children:
7f6a7c9, e01eb4a
Parents:
20737104
Message:

Fixed several warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/CodeGen/CodeGenerator.cc

    r20737104 r0bd46fd  
    277277                std::list< Declaration* > &memb = enumDecl->get_members();
    278278                if (enumDecl->base && ! memb.empty()) {
    279                         unsigned long long last_val = -1; // if the first enum value has no explicit initializer, 
    280                         // as other 
     279                        unsigned long long last_val = -1; // if the first enum value has no explicit initializer,
     280                        // as other
    281281                        for ( std::list< Declaration* >::iterator i = memb.begin(); i != memb.end();  i++) {
    282282                                ObjectDecl * obj = dynamic_cast< ObjectDecl* >( *i );
    283283                                assert( obj );
    284                                 output << "static const ";
    285                                 output << genType(enumDecl->base, "", options) << " ";
     284                                output << "static ";
     285                                output << genType(enumDecl->base, "", options) << " const ";
    286286                                output << mangleName( obj ) << " ";
    287287                                output << " = ";
     
    914914        }
    915915
    916         // QualifiedNameExpr should not reach to CodeGen. 
     916        // QualifiedNameExpr should not reach to CodeGen.
    917917        // FixQualifiedName Convert QualifiedNameExpr to VariableExpr
    918918        void CodeGenerator::postvisit( QualifiedNameExpr * expr ) {
Note: See TracChangeset for help on using the changeset viewer.