From ac1dfba8dd758febaf93f43e600d5542da6cd3e4 Mon Sep 17 00:00:00 2001 From: Yong He Date: Thu, 22 Feb 2018 15:08:47 -0500 Subject: Make `IRGlobalValue::mangledName` a `Name*` This allows us to get rid of `IRGlobalValue::dispose()`. --- source/slang/ir.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'source/slang/ir.h') diff --git a/source/slang/ir.h b/source/slang/ir.h index 3d4899824..8f350827a 100644 --- a/source/slang/ir.h +++ b/source/slang/ir.h @@ -20,7 +20,7 @@ class FuncType; class Layout; class Type; class Session; - +class Name; struct IRFunc; struct IRGlobalValueWithCode; struct IRInst; @@ -480,7 +480,7 @@ struct IRGlobalValue : IRValue // The mangled name, for a symbol that should have linkage, // or which might have multiple declarations. - String mangledName; + Name* mangledName = nullptr; IRGlobalValue* nextGlobalValue; @@ -500,11 +500,6 @@ struct IRGlobalValue : IRValue void removeFromParent(); void moveToEnd(); - virtual void dispose() override - { - IRValue::dispose(); - mangledName = String(); - } }; /// @brief A global value that potentially holds executable code. -- cgit v1.2.3