Changeset 1690778 for src/SynTree
- Timestamp:
- May 1, 2019, 7:49:16 AM (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:
- 3908e5d
- Parents:
- 98d4df9
- Location:
- src/SynTree
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SynTree/Declaration.h
r98d4df9 r1690778 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Sun Sep 3 19:24:06 201713 // Update Count : 13 112 // Last Modified On : Wed May 1 07:46:49 2019 13 // Update Count : 134 14 14 // 15 15 … … 19 19 #include <iosfwd> // for ostream 20 20 #include <list> // for list 21 #include <unordered_map> // for unordered_map 21 22 #include <string> // for string, operator+, allocator, to_string 22 23 … … 334 335 virtual Declaration *acceptMutator( Mutator &m ) override { return m.mutate( this ); } 335 336 private: 336 std:: map< std::string, long long int > enumValues;337 std::unordered_map< std::string, long long int > enumValues; 337 338 virtual std::string typeString() const override; 338 339 }; -
src/SynTree/TypeSubstitution.h
r98d4df9 r1690778 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Sat Jul 22 09:52:24 201713 // Update Count : 312 // Last Modified On : Tue Apr 30 22:52:47 2019 13 // Update Count : 9 14 14 // 15 15 … … 19 19 #include <iosfwd> // for ostream 20 20 #include <list> // for list<>::iterator, _List_iterator 21 #include < map> // for _Rb_tree_iterator, map, map<>::val...22 #include < set> // for set21 #include <unordered_map> 22 #include <unordered_set> 23 23 #include <string> // for string, operator!= 24 24 #include <utility> // for pair … … 78 78 friend class PassVisitor; 79 79 80 typedef std:: map< std::string, Type* > TypeEnvType;81 typedef std:: map< std::string, Expression* > VarEnvType;80 typedef std::unordered_map< std::string, Type * > TypeEnvType; 81 typedef std::unordered_map< std::string, Expression * > VarEnvType; 82 82 TypeEnvType typeEnv; 83 83 VarEnvType varEnv; … … 98 98 ActualIterator actualIt = actualBegin; 99 99 for ( ; formalIt != formalEnd; ++formalIt, ++actualIt ) { 100 if ( TypeDecl *formal = dynamic_cast< TypeDecl * >( *formalIt ) ) {101 if ( TypeExpr *actual = dynamic_cast< TypeExpr * >( *actualIt ) ) {100 if ( TypeDecl *formal = dynamic_cast< TypeDecl * >( *formalIt ) ) { 101 if ( TypeExpr *actual = dynamic_cast< TypeExpr * >( *actualIt ) ) { 102 102 if ( formal->get_name() != "" ) { 103 103 TypeEnvType::iterator i = typeEnv.find( formal->get_name() ); … … 146 146 int subCount = 0; 147 147 bool freeOnly; 148 typedef std:: set< std::string > BoundVarsType;148 typedef std::unordered_set< std::string > BoundVarsType; 149 149 BoundVarsType boundVars; 150 150 };
Note:
See TracChangeset
for help on using the changeset viewer.