#ifndef LLVM_ANALYSIS_DSSUPPORT_H
#define LLVM_ANALYSIS_DSSUPPORT_H
-#include <assert.h>
-
#include <vector>
#include <functional>
#include <string>
-#include "Support/HashExtras.h"
+#include <cassert>
#include "Support/hash_set"
class Function;
}
~DSNodeHandle() { setNode((DSNode*)0); }
DSNodeHandle &operator=(const DSNodeHandle &H) {
+ if (&H == this) return *this; // Don't set offset to 0 if self assigning.
Offset = 0; setNode(H.getNode()); Offset = H.Offset;
return *this;
}
InitNH(CallArgs[i], FromCall.CallArgs[i], NodeMap);
}
+ const DSCallSite &operator=(const DSCallSite &RHS) {
+ Inst = RHS.Inst;
+ CalleeF = RHS.CalleeF;
+ CalleeN = RHS.CalleeN;
+ RetVal = RHS.RetVal;
+ CallArgs = RHS.CallArgs;
+ return *this;
+ }
+
/// isDirectCall - Return true if this call site is a direct call of the
/// function specified by getCalleeFunc. If not, it is an indirect call to
/// the node specified by getCalleeNode.