Changeset c0d00b6 for src/ResolvExpr/Alternative.h
- Timestamp:
- Nov 25, 2017, 3:22:18 PM (8 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, cleanup-dtors, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- c6e2c18
- Parents:
- 9d06142 (diff), 3de176d (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
-
src/ResolvExpr/Alternative.h (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/ResolvExpr/Alternative.h
r9d06142 rc0d00b6 17 17 18 18 #include <iosfwd> // for ostream 19 #include < list> // for list19 #include <vector> // for vector 20 20 21 21 #include "Cost.h" // for Cost … … 25 25 26 26 namespace ResolvExpr { 27 struct Alternative;28 29 typedef std::list< Alternative > AltList;30 31 27 struct Alternative { 32 28 Alternative(); … … 41 37 void print( std::ostream &os, Indenter indent = {} ) const; 42 38 39 /// Returns the stored expression, but released from management of this Alternative 40 Expression* release_expr() { 41 Expression* tmp = expr; 42 expr = nullptr; 43 return tmp; 44 } 45 43 46 Cost cost; 44 47 Cost cvtCost; … … 46 49 TypeEnvironment env; 47 50 }; 51 52 typedef std::vector< Alternative > AltList; 53 54 /// Moves all elements from src to the end of dst 55 void splice( AltList& dst, AltList& src ); 56 57 /// Moves all elements from src to the beginning of dst 58 void spliceBegin( AltList& dst, AltList& src ); 48 59 } // namespace ResolvExpr 49 60
Note:
See TracChangeset
for help on using the changeset viewer.