summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/angle/src/compiler/translator/Types.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/angle/src/compiler/translator/Types.h')
-rw-r--r--src/3rdparty/angle/src/compiler/translator/Types.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/3rdparty/angle/src/compiler/translator/Types.h b/src/3rdparty/angle/src/compiler/translator/Types.h
index bc50a4dc64..075196daa3 100644
--- a/src/3rdparty/angle/src/compiler/translator/Types.h
+++ b/src/3rdparty/angle/src/compiler/translator/Types.h
@@ -140,6 +140,17 @@ class TStructure : public TFieldListCollection
private:
DISALLOW_COPY_AND_ASSIGN(TStructure);
+
+ // TODO(zmo): Find a way to get rid of the const_cast in function
+ // setName(). At the moment keep this function private so only
+ // friend class RegenerateStructNames may call it.
+ friend class RegenerateStructNames;
+ void setName(const TString &name)
+ {
+ TString *mutableName = const_cast<TString *>(mName);
+ *mutableName = name;
+ }
+
virtual TString mangledNamePrefix() const
{
return "struct-";