add a new CallGraphNode::replaceCallEdge method and use it from
commit69177fbaef43d051fcc9a84184b2884f41765c6b
authorChris Lattner <sabre@nondot.org>
Tue, 15 Sep 2009 05:40:35 +0000 (15 05:40 +0000)
committerChris Lattner <sabre@nondot.org>
Tue, 15 Sep 2009 05:40:35 +0000 (15 05:40 +0000)
tree66ec9d3d0df0527cbad15e8a2b07a7826b6ea039
parent5957ef5d5226035be8d48b37260bcef1b171a288
add a new CallGraphNode::replaceCallEdge method and use it from
argpromote to avoid invalidating an iterator.  This fixes PR4977.
All clang tests now pass with expensive checking (on my system
at least).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81843 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Analysis/CallGraph.h
lib/Analysis/IPA/CallGraph.cpp
lib/Transforms/IPO/ArgumentPromotion.cpp