diff options
| author | Frederic Riss <friss@apple.com> | 2014-09-15 07:50:36 +0000 |
|---|---|---|
| committer | Frederic Riss <friss@apple.com> | 2014-09-15 07:50:36 +0000 |
| commit | 36acf0fb8b8627bd586fe7df8872b1c8a17ab7cd (patch) | |
| tree | d1b634ac261eb7df0ab9f6309027887195e86bab /llvm/include | |
| parent | 4e126a0011973a63f2e674c2a08ab5f987bd0544 (diff) | |
| download | bcm5719-llvm-36acf0fb8b8627bd586fe7df8872b1c8a17ab7cd.tar.gz bcm5719-llvm-36acf0fb8b8627bd586fe7df8872b1c8a17ab7cd.zip | |
Move replaceAllUsesWith() from DIType to DIDescriptor.
RAUW was only used on DIType to merge declarations and full definitions
of types. In order to support the same functionality for functions and
global variables, move the function up type DI type hierarchy to the
common parent of DIType, DISubprogram and DIVariable which is
DIDescriptor.
This functionality will be exercized when we add the code to emit
imported declarations for forward declared function/variables.
Reviewers: echristo, dblaikie, aprantl
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D5325
llvm-svn: 217748
Diffstat (limited to 'llvm/include')
| -rw-r--r-- | llvm/include/llvm/IR/DebugInfo.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/include/llvm/IR/DebugInfo.h b/llvm/include/llvm/IR/DebugInfo.h index 7c58e33e964..f87095ba475 100644 --- a/llvm/include/llvm/IR/DebugInfo.h +++ b/llvm/include/llvm/IR/DebugInfo.h @@ -156,6 +156,11 @@ public: /// dump - print descriptor to dbgs() with a newline. void dump() const; + + /// replaceAllUsesWith - Replace all uses of debug info referenced by + /// this descriptor. + void replaceAllUsesWith(LLVMContext &VMContext, DIDescriptor D); + void replaceAllUsesWith(MDNode *D); }; /// DISubrange - This is used to represent ranges, for array bounds. @@ -352,11 +357,6 @@ public: return (getFlags() & FlagRValueReference) != 0; } bool isValid() const { return DbgNode && isType(); } - - /// replaceAllUsesWith - Replace all uses of debug info referenced by - /// this descriptor. - void replaceAllUsesWith(LLVMContext &VMContext, DIDescriptor D); - void replaceAllUsesWith(MDNode *D); }; /// DIBasicType - A basic type, like 'int' or 'float'. |

