Changes in src/Parser/parser.yy [24711a3:15f769c]
- File:
-
- 1 edited
-
src/Parser/parser.yy (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/Parser/parser.yy
r24711a3 r15f769c 10 10 // Created On : Sat Sep 1 20:22:55 2001 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Mon Apr 26 18:41:54202113 // Update Count : 499012 // Last Modified On : Sun Jun 20 18:46:51 2021 13 // Update Count : 5023 14 14 // 15 15 … … 269 269 %token INT128 UINT128 uuFLOAT80 uuFLOAT128 // GCC 270 270 %token uFLOAT16 uFLOAT32 uFLOAT32X uFLOAT64 uFLOAT64X uFLOAT128 // GCC 271 %token DECIMAL32 DECIMAL64 DECIMAL128 // GCC 271 272 %token ZERO_T ONE_T // CFA 272 273 %token SIZEOF TYPEOF VALIST AUTO_TYPE // GCC … … 287 288 288 289 // names and constants: lexer differentiates between identifier and typedef names 289 %token<tok> IDENTIFIER QUOTED_IDENTIFIER TYPED EFname TYPEGENname290 %token<tok> IDENTIFIER QUOTED_IDENTIFIER TYPEDIMname TYPEDEFname TYPEGENname 290 291 %token<tok> TIMEOUT WOR CATCH RECOVER CATCHRESUME FIXUP FINALLY // CFA 291 292 %token<tok> INTEGERconstant CHARACTERconstant STRINGliteral … … 586 587 | quasi_keyword 587 588 { $$ = new ExpressionNode( build_varref( $1 ) ); } 589 | TYPEDIMname // CFA, generic length argument 590 // { $$ = new ExpressionNode( new TypeExpr( maybeMoveBuildType( DeclarationNode::newFromTypedef( $1 ) ) ) ); } 591 // { $$ = new ExpressionNode( build_varref( $1 ) ); } 592 { $$ = new ExpressionNode( build_dimensionref( $1 ) ); } 588 593 | tuple 589 594 | '(' comma_expression ')' … … 1887 1892 | uFLOAT128 1888 1893 { $$ = DeclarationNode::newBasicType( DeclarationNode::uFloat128 ); } 1894 | DECIMAL32 1895 { SemanticError( yylloc, "_Decimal32 is currently unimplemented." ); $$ = nullptr; } 1896 | DECIMAL64 1897 { SemanticError( yylloc, "_Decimal64 is currently unimplemented." ); $$ = nullptr; } 1898 | DECIMAL128 1899 { SemanticError( yylloc, "_Decimal128 is currently unimplemented." ); $$ = nullptr; } 1889 1900 | COMPLEX // C99 1890 1901 { $$ = DeclarationNode::newComplexType( DeclarationNode::Complex ); } … … 2535 2546 | '[' identifier_or_type_name ']' 2536 2547 { 2537 typedefTable.addToScope( *$2, TYPED EFname, "9" );2538 $$ = DeclarationNode::newTypeParam( TypeDecl:: ALtype, $2 );2548 typedefTable.addToScope( *$2, TYPEDIMname, "9" ); 2549 $$ = DeclarationNode::newTypeParam( TypeDecl::Dimension, $2 ); 2539 2550 } 2540 2551 // | type_specifier identifier_parameter_declarator … … 2590 2601 { $$ = new ExpressionNode( new TypeExpr( maybeMoveBuildType( $1 ) ) ); } 2591 2602 | assignment_expression 2592 { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $1->build()) ); $$ = nullptr; }2593 2603 | type_list ',' type 2594 2604 { $$ = (ExpressionNode *)($1->set_last( new ExpressionNode( new TypeExpr( maybeMoveBuildType( $3 ) ) ) )); } 2595 2605 | type_list ',' assignment_expression 2596 { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $3->build()) ); $$ = nullptr; } 2597 // { $$ = (ExpressionNode *)( $1->set_last( $3 )); } 2606 { $$ = (ExpressionNode *)( $1->set_last( $3 )); } 2598 2607 ; 2599 2608
Note:
See TracChangeset
for help on using the changeset viewer.