Ignore:
Timestamp:
Dec 14, 2023, 9:05:55 PM (6 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
19a2890
Parents:
21ad568
Message:

second attempt at simplifying SemanticError? messages

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/TypeData.cc

    r21ad568 rca9d65e  
    1010// Created On       : Sat May 16 15:12:51 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sun Nov 26 15:51:05 2023
    13 // Update Count     : 681
     12// Last Modified On : Thu Dec 14 18:59:12 2023
     13// Update Count     : 684
    1414//
    1515
     
    14961496                                // type set => parameter name already transformed by a declaration names so there is a duplicate
    14971497                                // declaration name attempting a second transformation
    1498                                 if ( param->type ) SemanticError( param->location, string( "duplicate declaration name " ) + *param->name );
     1498                                if ( param->type ) SemanticError( param->location, "duplicate declaration name \"%s\".", param->name->c_str() );
    14991499                                // declaration type reset => declaration already transformed by a parameter name so there is a duplicate
    15001500                                // parameter name attempting a second transformation
    1501                                 if ( ! decl->type ) SemanticError( param->location, string( "duplicate parameter name " ) + *param->name );
     1501                                if ( ! decl->type ) SemanticError( param->location, "duplicate parameter name \"%s\".", param->name->c_str() );
    15021502                                param->type = decl->type;                               // set copy declaration type to parameter type
    15031503                                decl->type = nullptr;                                   // reset declaration type
Note: See TracChangeset for help on using the changeset viewer.