-//===-- llvm/Constant.h - Constant class definition --------------*- C++ -*--=//
+//===-- llvm/Constant.h - Constant class definition -------------*- C++ -*-===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file was developed by the LLVM research group and is distributed under
+// the University of Illinois Open Source License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
//
// This file contains the declaration of the Constant class.
//
#include "llvm/User.h"
+namespace llvm {
+
class Constant : public User {
protected:
inline Constant(const Type *Ty) : User(Ty, Value::ConstantVal) {}
/// use Value::replaceAllUsesWith, which automatically dispatches to this
/// method as needed.
///
- virtual void replaceUsesOfWithOnConstant(Value *From, Value *To) {
+ virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+ bool DisableChecking = false) {
// Provide a default implementation for constants (like integers) that
// cannot use any other values. This cannot be called at runtime, but needs
// to be here to avoid link errors.
// WARNING: Only to be used by Bytecode & Assembly Parsers! USER CODE SHOULD
// NOT USE THIS!!
// Returns the number of uses of OldV that were replaced.
- virtual unsigned mutateReferences(Value* OldV, Value *NewV) { return 0; }
+ unsigned mutateReferences(Value* OldV, Value *NewV);
// END WARNING!!
};
+} // End llvm namespace
+
#endif