summaryrefslogtreecommitdiff
path: root/src/mesa/shader/slang/Include
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2005-03-29 02:28:21 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2005-03-29 02:28:21 +0000
commit9a54843a94801a2253a05e2b4b93fbaf09b59e96 (patch)
tree400e7f2cfdd0c89c5d74d2938e0e50ec23723127 /src/mesa/shader/slang/Include
parentcb80e3905cfc3f38dc47cdf8936b6e33fdab9648 (diff)
fix a variety of warnings/errors
Diffstat (limited to 'src/mesa/shader/slang/Include')
-rwxr-xr-xsrc/mesa/shader/slang/Include/Common.h5
-rwxr-xr-xsrc/mesa/shader/slang/Include/PoolAlloc.h2
-rwxr-xr-xsrc/mesa/shader/slang/Include/ShHandle.h2
-rwxr-xr-xsrc/mesa/shader/slang/Include/Types.h23
4 files changed, 18 insertions, 14 deletions
diff --git a/src/mesa/shader/slang/Include/Common.h b/src/mesa/shader/slang/Include/Common.h
index bd1aaa8fcf..4a9c0d34a7 100755
--- a/src/mesa/shader/slang/Include/Common.h
+++ b/src/mesa/shader/slang/Include/Common.h
@@ -230,7 +230,10 @@ public:
typedef pool_allocator<std::pair <K, D> > tAllocator;
TMap() : TBaseMap<K, D, CMP, tAllocator >() {}
+/*
TMap(const tAllocator& a) : TBaseMap<K, D, CMP, tAllocator >(key_compare(), a) {}
+*/
+ TMap(const tAllocator& a) : TBaseMap<K, D, CMP, tAllocator >() {}
};
//
@@ -275,7 +278,7 @@ __inline TPersistString FormatSourceLoc(const TSourceLoc loc)
if (line)
sprintf(locText, "%d:%d", string, line);
else
- sprintf(locText, "%d:? ", string, line);
+ sprintf(locText, "%d:? ", string);
return TPersistString(locText);
}
diff --git a/src/mesa/shader/slang/Include/PoolAlloc.h b/src/mesa/shader/slang/Include/PoolAlloc.h
index 3649981ef2..e224d3b867 100755
--- a/src/mesa/shader/slang/Include/PoolAlloc.h
+++ b/src/mesa/shader/slang/Include/PoolAlloc.h
@@ -287,7 +287,7 @@ public:
pool_allocator(const pool_allocator<T>& p) : allocator(p.allocator) { }
#endif
-#if _MSC_VER >= 1300
+#if defined(_MSC_VER) && _MSC_VER >= 1300
template<class Other>
#ifdef USING_SGI_STL
pool_allocator(const pool_allocator<Other>& p) /*: allocator(p.getAllocator())*/ { }
diff --git a/src/mesa/shader/slang/Include/ShHandle.h b/src/mesa/shader/slang/Include/ShHandle.h
index 6c654bdde2..82c0314f34 100755
--- a/src/mesa/shader/slang/Include/ShHandle.h
+++ b/src/mesa/shader/slang/Include/ShHandle.h
@@ -53,7 +53,7 @@ namespace Lf {
class TBindingList;
class TLinker;
class TLibrary;
-};
+}
//
// The base class used to back handles returned to the driver.
diff --git a/src/mesa/shader/slang/Include/Types.h b/src/mesa/shader/slang/Include/Types.h
index cd5a8617cb..9415879afe 100755
--- a/src/mesa/shader/slang/Include/Types.h
+++ b/src/mesa/shader/slang/Include/Types.h
@@ -83,12 +83,12 @@ class TType {
public:
POOL_ALLOCATOR_NEW_DELETE(GlobalPoolAllocator)
explicit TType(TBasicType t, TQualifier q = EvqTemporary, int s = 1, bool m = false, bool a = false) :
- type(t), qualifier(q), size(s), matrix(m), array(a), arraySize(0),
- structure(0), structureSize(0), maxArraySize(0), arrayInformationType(0), typeName(0), mangled(0), fieldName(0)
+ type(t), qualifier(q), size(s), matrix(m), array(a), arraySize(0), structure(0),
+ structureSize(0), maxArraySize(0), arrayInformationType(0), fieldName(0), typeName(0), mangled(0)
{ }
explicit TType(TPublicType p) :
type(p.type), qualifier(p.qualifier), size(p.size), matrix(p.matrix), array(p.array), arraySize(0),
- structure(0), structureSize(0), maxArraySize(0), arrayInformationType(0), fieldName(0), mangled(0), typeName(0)
+ structure(0), structureSize(0), maxArraySize(0), arrayInformationType(0), fieldName(0), typeName(0), mangled(0)
{
if (p.userDef) {
structure = p.userDef->getStruct();
@@ -277,20 +277,21 @@ public:
protected:
void buildMangledName(TString&);
+ TBasicType type : 6;
+ TQualifier qualifier : 7;
+ int size : 8; // size of vector or matrix, not size of array
+ unsigned int matrix : 1;
+ unsigned int array : 1;
+
int arraySize;
TTypeList* structure; // 0 unless this is a struct
- TString *fieldName; // for structure field names
- TString *typeName; // for structure field type name
- TString *mangled;
int structureSize;
int maxArraySize;
TType* arrayInformationType;
+ TString *fieldName; // for structure field names
+ TString *typeName; // for structure field type name
+ TString *mangled;
- TQualifier qualifier : 7;
- TBasicType type : 6;
- int size : 8; // size of vector or matrix, not size of array
- unsigned int matrix : 1;
- unsigned int array : 1;
};
#endif // _TYPES_INCLUDED_