Fix g++ build break (portibility problems with stl hash). This partly turns off the stl improvements.
It also removes some old code that ancient compilers used to need. However, the main issue is getting access to hash functions for unordered_map in portable way.
This commit is contained in:
parent
6ab3d582d6
commit
68965c0fa9
4 changed files with 12 additions and 25 deletions
|
|
@ -306,7 +306,8 @@ protected:
|
|||
TInputScanner* currentScanner;
|
||||
int numErrors; // number of compile-time errors encountered
|
||||
bool parsingBuiltins; // true if parsing built-in symbols/functions
|
||||
TUnorderedMap<TString, TExtensionBehavior> extensionBehavior; // for each extension string, what its current behavior is set to
|
||||
// need portable TStringHash TUnorderedMap<TString, TExtensionBehavior, TStringHash> extensionBehavior; // for each extension string, what its current behavior is set to
|
||||
TMap<TString, TExtensionBehavior> extensionBehavior; // for each extension string, what its current behavior is set to
|
||||
static const int maxSamplerIndex = EsdNumDims * (EbtNumTypes * (2 * 2 * 2)); // see computeSamplerTypeIndex()
|
||||
TPrecisionQualifier defaultSamplerPrecision[maxSamplerIndex];
|
||||
bool afterEOF;
|
||||
|
|
|
|||
|
|
@ -192,7 +192,8 @@ public:
|
|||
};
|
||||
|
||||
MemoryPool *pool;
|
||||
typedef TUnorderedMap<int, Symbol*> TSymbolMap;
|
||||
// need portable hash typedef TUnorderedMap<int, Symbol*> TSymbolMap;
|
||||
typedef TMap<int, Symbol*> TSymbolMap;
|
||||
TSymbolMap symbols; // this has light use... just defined macros
|
||||
|
||||
protected:
|
||||
|
|
@ -436,7 +437,8 @@ protected:
|
|||
//
|
||||
// From PpAtom.cpp
|
||||
//
|
||||
typedef TUnorderedMap<const TString, int, TStringHash> TAtomMap;
|
||||
// need portable TStringHash typedef TUnorderedMap<const TString, int, TStringHash> TAtomMap;
|
||||
typedef TMap<const TString, int> TAtomMap;
|
||||
typedef TVector<const TString*> TStringMap;
|
||||
TAtomMap atomMap;
|
||||
TStringMap stringMap;
|
||||
|
|
|
|||
|
|
@ -108,7 +108,8 @@ public:
|
|||
protected:
|
||||
friend class glslang::TLiveTraverser;
|
||||
|
||||
typedef std::unordered_map<TString, int> TNameToIndex;
|
||||
// Need a TString hash: typedef std::unordered_map<TString, int> TNameToIndex;
|
||||
typedef std::map<TString, int> TNameToIndex;
|
||||
typedef std::vector<TObjectReflection> TMapIndexToReflection;
|
||||
|
||||
TObjectReflection badReflection; // return for queries of -1 or generally out of range; has expected descriptions with in it for this
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue