Changeset 0522ebe for src/Parser


Ignore:
Timestamp:
Feb 26, 2024, 3:49:23 AM (5 months ago)
Author:
JiadaL <j82liang@…>
Branches:
master
Children:
a4da45e
Parents:
c17dc80
Message:

Add EnumPosType? to type system

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    rc17dc80 r0522ebe  
    30063006        | assertion_list
    30073007                { $$ = DeclarationNode::newTypeParam( ast::TypeDecl::Dtype, new string( DeclarationNode::anonymous.newName() ) )->addAssertions( $1 ); }
     3008        | ENUM '(' identifier_or_type_name ')' identifier_or_type_name new_type_class type_initializer_opt assertion_list_opt
     3009                {       
     3010                        typedefTable.addToScope( *$3, TYPEDIMname, "type_parameter 4" );
     3011                        typedefTable.addToScope( *$5, TYPEDIMname, "type_parameter 5" );
     3012                        $$ = DeclarationNode::newTypeParam( $6, $5 )->addTypeInitializer( $7 )->addAssertions( $8 );
     3013                }
    30083014        ;
    30093015
Note: See TracChangeset for help on using the changeset viewer.