Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/ResolvExpr/AlternativeFinder.cc

    r624b722d rd55d7a6  
    252252                                std::cerr << "No reasonable alternatives for expression " << expr << std::endl;
    253253                        )
    254                         throw SemanticError( "No reasonable alternatives for expression ", expr );
     254                        throw SemanticError( expr, "No reasonable alternatives for expression " );
    255255                }
    256256                if ( prune ) {
     
    270270                                stream << "Alternatives are:\n";
    271271                                printAlts( winners, stream, 1 );
    272                                 throw SemanticError( stream.str() );
     272                                throw SemanticError( expr->location, stream.str() );
    273273                        }
    274274                        alternatives = move(pruned);
     
    507507                                return;
    508508                        } else if ( level >= recursionLimit ) {
    509                                 throw SemanticError( "Too many recursive assertions" );
     509                                throw SemanticError( newAlt.expr->location, "Too many recursive assertions" );
    510510                        } else {
    511511                                AssertionSet newerNeed;
     
    14211421                        findMinCost( finder.alternatives.begin(), finder.alternatives.end(), back_inserter( winners ) );
    14221422                        if ( winners.size() != 1 ) {
    1423                                 throw SemanticError( "Ambiguous expression in sizeof operand: ", sizeofExpr->get_expr() );
     1423                                throw SemanticError( sizeofExpr->get_expr(), "Ambiguous expression in sizeof operand: " );
    14241424                        } // if
    14251425                        // return the lowest cost alternative for the argument
     
    14421442                        findMinCost( finder.alternatives.begin(), finder.alternatives.end(), back_inserter( winners ) );
    14431443                        if ( winners.size() != 1 ) {
    1444                                 throw SemanticError( "Ambiguous expression in alignof operand: ", alignofExpr->get_expr() );
     1444                                throw SemanticError( alignofExpr->get_expr(), "Ambiguous expression in alignof operand: " );
    14451445                        } // if
    14461446                        // return the lowest cost alternative for the argument
Note: See TracChangeset for help on using the changeset viewer.