Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/ResolvExpr/CastCost.cpp

    r90e683b r115ac1ce  
    5353                void postvisit( const ast::EnumInstType * enumInst ) {
    5454                        cost = conversionCost( enumInst, dst, srcIsLvalue, symtab, env );
    55                         if ( enumInst->base->is_typed_enum() ) {
    56                                 auto baseConversionCost =
     55                        if ( enumInst->base->isTyped() ) {
     56                                auto baseConversionCost = 
    5757                                        castCost( enumInst->base->base, dst, srcIsLvalue, symtab, env );
    58                                 cost = baseConversionCost < cost ? baseConversionCost : cost;
     58                                cost = baseConversionCost < cost? baseConversionCost: cost;
    5959                        }
    6060                        static ast::ptr<ast::BasicType> integer = { new ast::BasicType( ast::BasicKind::SignedInt ) };
    6161                        Cost intCost = costCalc( integer, dst, srcIsLvalue, symtab, env );
    6262                        intCost.incSafe();
    63                         cost = intCost < cost ? intCost : cost;
     63                        cost = intCost < cost? intCost: cost;
    6464                }
    6565
Note: See TracChangeset for help on using the changeset viewer.