Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/GenPoly.cc

    ra0d1f1c re9b5043  
    172172
    173173                if ( TypeInstType *typeInst = dynamic_cast< TypeInstType * >( type ) ) {
    174                         if ( tyVars.find( typeInst->get_name() ) != tyVars.end() ) {
     174                        if ( tyVars.contains( typeInst->get_name() ) ) {
    175175                                return type;
    176176                        }
     
    189189
    190190                if ( auto typeInst = dynamic_cast< const ast::TypeInstType * >( type ) ) {
    191                         return tyVars.find(typeInst->typeString()) != tyVars.end() ? type : nullptr;
     191                        if ( tyVars.contains( typeInst->typeString() ) ) return type;
    192192                } else if ( auto arrayType = dynamic_cast< const ast::ArrayType * >( type ) ) {
    193193                        return isPolyType( arrayType->base, env );
     
    205205
    206206        if ( auto inst = dynamic_cast< const ast::TypeInstType * >( type ) ) {
    207                 if ( typeVars.find( *inst ) != typeVars.end() ) return type;
     207                if ( typeVars.contains( *inst ) ) return type;
    208208        } else if ( auto array = dynamic_cast< const ast::ArrayType * >( type ) ) {
    209209                return isPolyType( array->base, subst );
     
    393393
    394394                if ( TypeInstType *typeInstType = dynamic_cast< TypeInstType * >( type ) ) {
    395                         if ( tyVars.find( typeInstType->get_name() ) != tyVars.end() ) {
     395                        if ( tyVars.contains( typeInstType->get_name() ) ) {
    396396                                return true;
    397397                        }
Note: See TracChangeset for help on using the changeset viewer.