Move replaceAllUsesWith() from DIType to DIDescriptor.
authorFrederic Riss <friss@apple.com>
Mon, 15 Sep 2014 07:50:36 +0000 (07:50 +0000)
committerFrederic Riss <friss@apple.com>
Mon, 15 Sep 2014 07:50:36 +0000 (07:50 +0000)
commit04dc1486ac17350b9d1f812acc847391f3d8d696
tree5879675c7e49b70845d7e44e92b91ee42c603cc3
parentea3ce67d712a83c683732769aa1d8e6607a92613
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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217748 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/IR/DebugInfo.h
lib/IR/DebugInfo.cpp