Ignore:
Timestamp:
Sep 1, 2023, 3:54:42 PM (2 years ago)
Author:
caparsons <caparson@…>
Branches:
master
Children:
4b30318b
Parents:
4269d1b (diff), 4c0fa03 (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.
Message:

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Validate/GenericParameter.cpp

    r4269d1b r8a9a3ab  
    301301const ast::Expr * TranslateDimensionCore::postvisit(
    302302                const ast::TypeExpr * expr ) {
    303         // Does nothing, except prevents matching ast::Expr (above).
     303        if ( auto instType = dynamic_cast<const ast::EnumInstType *>( expr->type.get() ) ) {
     304                const ast::EnumDecl * baseEnum = instType->base.get();
     305                return ast::ConstantExpr::from_int( expr->location, baseEnum->members.size() );
     306        }
    304307        return expr;
    305308}
Note: See TracChangeset for help on using the changeset viewer.