Changeset 9d23c2d
- Timestamp:
- May 22, 2019, 1:03:56 PM (6 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:
- 15934a6
- Parents:
- 20de6fb (diff), 3f840e3 (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. - Location:
- src
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
src/AST/Bitfield.hpp
r20de6fb r9d23c2d 57 57 }; 58 58 59 /// Adds default printing operator to a bitfield type. 60 /// Include in definition to add print function, requires other bitfield operators. 61 /// @param N Number of bits in bitfield 62 #define MakeBitfieldPrint( N ) \ 63 static const char* Names[]; \ 64 \ 65 void print( std::ostream & os ) const { \ 66 if ( (*this).any() ) { \ 67 for ( unsigned int i = 0; i < N; i += 1 ) { \ 68 if ( (*this)[i] ) { \ 69 os << Names[i] << ' '; \ 70 } \ 71 } \ 72 } \ 73 } 59 template<typename T> 60 inline bool operator== ( const bitfield<T> & a, const bitfield<T> & b ) { 61 return a.val == b.val; 62 } 63 64 template<typename T> 65 inline bool operator!= ( const bitfield<T> & a, const bitfield<T> & b ) { 66 return !(a == b); 67 } 74 68 75 69 // Local Variables: // -
src/AST/Node.cpp
r20de6fb r9d23c2d 26 26 #include "Type.hpp" 27 27 #include "TypeSubstitution.hpp" 28 29 #include "Print.hpp" 28 30 29 31 template< typename node_t, enum ast::Node::ref_type ref_t > … … 47 49 48 50 std::ostream & ast::operator<< ( std::ostream & out, const ast::Node * node ) { 49 (void)node; 50 #warning unimplemented 51 assertf(false, "Unimplemented"); 51 print(out, node); 52 52 return out; 53 53 } -
src/AST/module.mk
r20de6fb r9d23c2d 24 24 AST/LinkageSpec.cpp \ 25 25 AST/Node.cpp \ 26 AST/Print.cpp \ 26 27 AST/Stmt.cpp \ 27 28 AST/Type.cpp \ -
src/Makefile.in
r20de6fb r9d23c2d 169 169 AST/Expr.$(OBJEXT) AST/Init.$(OBJEXT) \ 170 170 AST/LinkageSpec.$(OBJEXT) AST/Node.$(OBJEXT) \ 171 AST/ Stmt.$(OBJEXT) AST/Type.$(OBJEXT) \171 AST/Print.$(OBJEXT) AST/Stmt.$(OBJEXT) AST/Type.$(OBJEXT) \ 172 172 AST/TypeSubstitution.$(OBJEXT) 173 173 am__objects_2 = CodeGen/CodeGenerator.$(OBJEXT) \ … … 577 577 AST/LinkageSpec.cpp \ 578 578 AST/Node.cpp \ 579 AST/Print.cpp \ 579 580 AST/Stmt.cpp \ 580 581 AST/Type.cpp \ … … 741 742 AST/$(DEPDIR)/$(am__dirstamp) 742 743 AST/Node.$(OBJEXT): AST/$(am__dirstamp) AST/$(DEPDIR)/$(am__dirstamp) 744 AST/Print.$(OBJEXT): AST/$(am__dirstamp) AST/$(DEPDIR)/$(am__dirstamp) 743 745 AST/Stmt.$(OBJEXT): AST/$(am__dirstamp) AST/$(DEPDIR)/$(am__dirstamp) 744 746 AST/Type.$(OBJEXT): AST/$(am__dirstamp) AST/$(DEPDIR)/$(am__dirstamp) … … 1172 1174 @AMDEP_TRUE@@am__include@ @am__quote@AST/$(DEPDIR)/LinkageSpec.Po@am__quote@ 1173 1175 @AMDEP_TRUE@@am__include@ @am__quote@AST/$(DEPDIR)/Node.Po@am__quote@ 1176 @AMDEP_TRUE@@am__include@ @am__quote@AST/$(DEPDIR)/Print.Po@am__quote@ 1174 1177 @AMDEP_TRUE@@am__include@ @am__quote@AST/$(DEPDIR)/Stmt.Po@am__quote@ 1175 1178 @AMDEP_TRUE@@am__include@ @am__quote@AST/$(DEPDIR)/Type.Po@am__quote@
Note: See TracChangeset
for help on using the changeset viewer.