Changes in / [79caea8:610194e]


Ignore:
Location:
src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/parser.yy

    r79caea8 r610194e  
    23072307                { $$ = new ExpressionNode( new TypeExpr( maybeMoveBuildType( $1 ) ) ); }
    23082308        | assignment_expression
     2309                { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $1->build()) ); $$ = nullptr; }
    23092310        | type_list ',' type
    23102311                { $$ = (ExpressionNode *)( $1->set_last( new ExpressionNode( new TypeExpr( maybeMoveBuildType( $3 ) ) ) ) ); }
    23112312        | type_list ',' assignment_expression
    2312                 { $$ = (ExpressionNode *)( $1->set_last( $3 )); }
     2313                { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $3->build()) ); $$ = nullptr; }
     2314                // { $$ = (ExpressionNode *)( $1->set_last( $3 )); }
    23132315        ;
    23142316
  • src/ResolvExpr/AlternativeFinder.cc

    r79caea8 r610194e  
    482482        template< typename ForwardIterator, typename OutputIterator >
    483483        void inferRecursive( ForwardIterator begin, ForwardIterator end, const Alternative &newAlt, OpenVarSet &openVars, const SymTab::Indexer &decls, const AssertionSet &newNeed, int level, const SymTab::Indexer &indexer, OutputIterator out ) {
     484                if ( newAlt.cost == Cost::infinity ) return; // don't proceed down this dead end
    484485                if ( begin == end ) {
    485486                        if ( newNeed.empty() ) {
     
    11851186                                std::cerr << "bindings are:" << std::endl;
    11861187                                withFunc.env.print( std::cerr, 8 );
     1188                                std::cerr << "cost is: " << withFunc.cost << std::endl;
    11871189                                std::cerr << "cost of conversion is:" << cvtCost << std::endl;
    11881190                        )
  • src/ResolvExpr/CommonType.cc

    r79caea8 r610194e  
    267267                                                result = otherPointer->clone();
    268268                                        } // if
    269                                         result->get_qualifiers() = tq1 | tq2;
     269                                        strict_dynamic_cast<PointerType*>(result)->base->get_qualifiers() = tq1 | tq2;
    270270                                } else {
    271271                                        /// std::cerr << "place for ptr-to-type" << std::endl;
     
    304304                                                result = otherRef->clone();
    305305                                        } // if
    306                                         result->get_qualifiers() = tq1 | tq2;
     306                                        strict_dynamic_cast<ReferenceType*>(result)->base->get_qualifiers() = tq1 | tq2;
    307307                                } else {
    308308                                        /// std::cerr << "place for ptr-to-type" << std::endl;
  • src/SymTab/FixFunction.cc

    r79caea8 r610194e  
    3030                // can't delete function type because it may contain assertions, so transfer ownership to new object
    3131                ObjectDecl *pointer = new ObjectDecl( functionDecl->name, functionDecl->get_storageClasses(), functionDecl->linkage, nullptr, new PointerType( Type::Qualifiers(), functionDecl->type ), nullptr, functionDecl->attributes );
     32                pointer->location = functionDecl->location;
    3233                functionDecl->attributes.clear();
    3334                functionDecl->type = nullptr;
     
    4344                // need to recursively mutate the base type in order for multi-dimensional arrays to work.
    4445                PointerType *pointerType = new PointerType( arrayType->get_qualifiers(), arrayType->base, arrayType->dimension, arrayType->isVarLen, arrayType->isStatic );
     46                pointerType->location = arrayType->location;
    4547                arrayType->base = nullptr;
    4648                arrayType->dimension = nullptr;
Note: See TracChangeset for help on using the changeset viewer.