diff options
author | Rhys Weatherley <rhys.weatherley@nokia.com> | 2010-12-01 13:19:22 +1000 |
---|---|---|
committer | Rhys Weatherley <rhys.weatherley@nokia.com> | 2010-12-01 13:19:22 +1000 |
commit | 9af4436875df8c1f8c5916c702ee15d237105710 (patch) | |
tree | d047e1b6212781fe6873d4e91a55e3d067cee7a2 /src | |
parent | 045c7fd513ed3a939ea085fcfb7bc09ed8ec5ffa (diff) | |
download | qt-creator-9af4436875df8c1f8c5916c702ee15d237105710.tar.gz |
GLSL array type toString() implementation
Diffstat (limited to 'src')
-rw-r--r-- | src/libs/glsl/glsltypes.cpp | 5 | ||||
-rw-r--r-- | src/libs/glsl/glsltypes.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/libs/glsl/glsltypes.cpp b/src/libs/glsl/glsltypes.cpp index 555d1839bf..c4f9e577c3 100644 --- a/src/libs/glsl/glsltypes.cpp +++ b/src/libs/glsl/glsltypes.cpp @@ -309,6 +309,11 @@ bool MatrixType::isLessThan(const Type *other) const return false; } +QString ArrayType::toString() const +{ + return elementType()->toString() + QLatin1String("[]"); +} + bool ArrayType::isEqualTo(const Type *other) const { if (other) { diff --git a/src/libs/glsl/glsltypes.h b/src/libs/glsl/glsltypes.h index 04559f2172..fd0b934a74 100644 --- a/src/libs/glsl/glsltypes.h +++ b/src/libs/glsl/glsltypes.h @@ -181,6 +181,7 @@ public: const Type *elementType() const { return indexElementType(); } + virtual QString toString() const; virtual const ArrayType *asArrayType() const { return this; } virtual bool isEqualTo(const Type *other) const; virtual bool isLessThan(const Type *other) const; |