Changeset c494b84 for src/Parser


Ignore:
Timestamp:
Sep 13, 2024, 2:43:05 PM (2 months ago)
Author:
JiadaL <j82liang@…>
Branches:
master
Children:
5ef4008
Parents:
a35e342
Message:

The fix about build enum type (I thought I have pushed it)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/TypeData.cpp

    ra35e342 rc494b84  
    14541454        assert( td->kind == TypeData::Aggregate );
    14551455        assert( td->aggregate.kind == ast::AggregateDecl::Enum );
    1456         ast::ptr<ast::Type> baseType = td->base ? typebuild(td->base) : nullptr;
    1457 
     1456        ast::ptr<ast::Type> baseType;
     1457        if ( td->base ) {
     1458                if ( td->base->kind == TypeData::Aggregate ) {
     1459                        baseType = buildComAggInst( td->base, copy(attributes), linkage );
     1460                } else {
     1461                        baseType = typebuild( td->base );
     1462                }
     1463        }
    14581464        ast::EnumDecl * ret = new ast::EnumDecl(
    14591465                td->location,
Note: See TracChangeset for help on using the changeset viewer.