mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-22 23:24:59 +00:00
It doesn't make sense for one side to be const, but not the other.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10952 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -326,7 +326,7 @@ inline DSNode *DSNodeHandle::getNode() const {
|
||||
return HandleForwarding();
|
||||
}
|
||||
|
||||
inline void DSNodeHandle::setNode(DSNode *n) {
|
||||
inline void DSNodeHandle::setNode(DSNode *n) const {
|
||||
assert(!n || !n->getForwardNode() && "Cannot set node to a forwarded node!");
|
||||
if (N) N->NumReferrers--;
|
||||
N = n;
|
||||
@@ -377,11 +377,14 @@ inline void DSNodeHandle::addEdgeTo(unsigned Off, const DSNodeHandle &Node) {
|
||||
/// mergeWith - Merge the logical node pointed to by 'this' with the node
|
||||
/// pointed to by 'N'.
|
||||
///
|
||||
inline void DSNodeHandle::mergeWith(const DSNodeHandle &Node) {
|
||||
if (N != 0)
|
||||
inline void DSNodeHandle::mergeWith(const DSNodeHandle &Node) const {
|
||||
if (!isNull())
|
||||
getNode()->mergeWith(Node, Offset);
|
||||
else // No node to merge with, so just point to Node
|
||||
*this = Node;
|
||||
else { // No node to merge with, so just point to Node
|
||||
Offset = 0;
|
||||
setNode(Node.getNode());
|
||||
Offset = Node.getOffset();
|
||||
}
|
||||
}
|
||||
|
||||
} // End llvm namespace
|
||||
|
Reference in New Issue
Block a user