Changes in src/AST/Expr.hpp [20de6fb:17a0228a]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/AST/Expr.hpp
r20de6fb r17a0228a 30 30 #define MUTATE_FRIEND template<typename node_t> friend node_t * mutate(const node_t * node); 31 31 32 class ConverterOldToNew;33 34 32 namespace ast { 35 33 … … 108 106 case Params: assert(!"Cannot return to resnSlots from Params"); 109 107 } 110 return *((ResnSlots*)nullptr);111 }112 113 const ResnSlots& resnSlotsConst() const {114 if (mode == Slots) {115 return data.resnSlots;116 }117 assert(!"Mode was not already resnSlots");118 return *((ResnSlots*)nullptr);119 108 } 120 109 … … 125 114 case Params: return data.inferParams; 126 115 } 127 return *((InferredParams*)nullptr);128 }129 130 const InferredParams& inferParamsConst() const {131 if (mode == Params) {132 return data.inferParams;133 }134 assert(!"Mode was not already Params");135 return *((InferredParams*)nullptr);136 116 } 137 117 }; … … 530 510 std::vector<ptr<ObjectDecl>> tempDecls; 531 511 std::vector<ptr<ObjectDecl>> returnDecls; 532 std::vector<ptr< Expr>> dtors;512 std::vector<ptr<ObjectDecl>> dtors; 533 513 534 514 ImplicitCopyCtorExpr( const CodeLocation& loc, const ApplicationExpr * call ) … … 637 617 638 618 const Expr * accept( Visitor & v ) const override { return v.visit( this ); } 639 640 friend class ::ConverterOldToNew;641 642 619 private: 643 620 TupleAssignExpr * clone() const override { return new TupleAssignExpr{ *this }; } 644 TupleAssignExpr( const CodeLocation & loc, const Type * result, const StmtExpr * s );645 646 621 MUTATE_FRIEND 647 622 };
Note: See TracChangeset
for help on using the changeset viewer.