Changeset 3d937e2 for src


Ignore:
Timestamp:
Feb 25, 2023, 3:38:51 PM (14 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, ast-experimental, master
Children:
2d028003
Parents:
be00a2d
Message:

remove warnings for incorrect usage of SuperfluousElse? and DeprecTraitSyntax? in parser

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    rbe00a2d r3d937e2  
    1010// Created On       : Sat Sep  1 20:22:55 2001
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Feb 25 09:52:06 2023
    13 // Update Count     : 5986
     12// Last Modified On : Sat Feb 25 13:23:16 2023
     13// Update Count     : 5989
    1414//
    1515
     
    12801280                {
    12811281                        $$ = new StatementNode( build_while( new CondCtl( nullptr, NEW_ONE ), maybe_build_compound( $4 ) ) );
    1282                         SemanticWarning( yylloc, Warning::SuperfluousElse, "" );
     1282                        SemanticWarning( yylloc, Warning::SuperfluousElse );
    12831283                }
    12841284        | WHILE '(' conditional_declaration ')' statement       %prec THEN
     
    12911291                {
    12921292                        $$ = new StatementNode( build_do_while( NEW_ONE, maybe_build_compound( $2 ) ) );
    1293                         SemanticWarning( yylloc, Warning::SuperfluousElse, "" );
     1293                        SemanticWarning( yylloc, Warning::SuperfluousElse );
    12941294                }
    12951295        | DO statement WHILE '(' comma_expression ')' ';'
     
    13021302                {
    13031303                        $$ = new StatementNode( build_for( new ForCtrl( (ExpressionNode * )nullptr, (ExpressionNode * )nullptr, (ExpressionNode * )nullptr ), maybe_build_compound( $4 ) ) );
    1304                         SemanticWarning( yylloc, Warning::SuperfluousElse, "" );
     1304                        SemanticWarning( yylloc, Warning::SuperfluousElse );
    13051305                }
    13061306        | FOR '(' for_control_expression_list ')' statement     %prec THEN
     
    29902990        TRAIT identifier_or_type_name '(' type_parameter_list ')' '{' '}'
    29912991                {
    2992                         SemanticWarning( yylloc, Warning::DeprecTraitSyntax, "" );
     2992                        SemanticWarning( yylloc, Warning::DeprecTraitSyntax );
    29932993                        $$ = DeclarationNode::newTrait( $2, $4, nullptr );
    29942994                }
     
    29972997        | TRAIT identifier_or_type_name '(' type_parameter_list ')' '{' push trait_declaration_list pop '}'
    29982998                {
    2999                         SemanticWarning( yylloc, Warning::DeprecTraitSyntax, "" );
     2999                        SemanticWarning( yylloc, Warning::DeprecTraitSyntax );
    30003000                        $$ = DeclarationNode::newTrait( $2, $4, $8 );
    30013001                }
Note: See TracChangeset for help on using the changeset viewer.