summaryrefslogtreecommitdiff
path: root/utils/TableGen/Record.h
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-03-25 22:06:05 +0000
committerDan Gohman <gohman@apple.com>2008-03-25 22:06:05 +0000
commit950a4c40b823cd4f09dc71be635229246dfd6cac (patch)
treeff52517c682e08112a66247bc8b85f81664f72b3 /utils/TableGen/Record.h
parentcfbb2f074da2842e42956d3b4c21e91b37f36f06 (diff)
downloadllvm-950a4c40b823cd4f09dc71be635229246dfd6cac.tar.gz
llvm-950a4c40b823cd4f09dc71be635229246dfd6cac.tar.bz2
llvm-950a4c40b823cd4f09dc71be635229246dfd6cac.tar.xz
Add explicit keywords.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48801 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen/Record.h')
-rw-r--r--utils/TableGen/Record.h19
1 files changed, 10 insertions, 9 deletions
diff --git a/utils/TableGen/Record.h b/utils/TableGen/Record.h
index 5f0e4c7fa6..83d358ad2c 100644
--- a/utils/TableGen/Record.h
+++ b/utils/TableGen/Record.h
@@ -509,7 +509,7 @@ public:
class BitInit : public Init {
bool Value;
public:
- BitInit(bool V) : Value(V) {}
+ explicit BitInit(bool V) : Value(V) {}
bool getValue() const { return Value; }
@@ -526,7 +526,7 @@ public:
class BitsInit : public Init {
std::vector<Init*> Bits;
public:
- BitsInit(unsigned Size) : Bits(Size) {}
+ explicit BitsInit(unsigned Size) : Bits(Size) {}
unsigned getNumBits() const { return Bits.size(); }
@@ -567,7 +567,7 @@ public:
class IntInit : public Init {
int Value;
public:
- IntInit(int V) : Value(V) {}
+ explicit IntInit(int V) : Value(V) {}
int getValue() const { return Value; }
@@ -585,7 +585,7 @@ public:
class StringInit : public Init {
std::string Value;
public:
- StringInit(const std::string &V) : Value(V) {}
+ explicit StringInit(const std::string &V) : Value(V) {}
const std::string &getValue() const { return Value; }
@@ -601,7 +601,7 @@ public:
class CodeInit : public Init {
std::string Value;
public:
- CodeInit(const std::string &V) : Value(V) {}
+ explicit CodeInit(const std::string &V) : Value(V) {}
const std::string getValue() const { return Value; }
@@ -617,7 +617,7 @@ public:
class ListInit : public Init {
std::vector<Init*> Values;
public:
- ListInit(std::vector<Init*> &Vs) {
+ explicit ListInit(std::vector<Init*> &Vs) {
Values.swap(Vs);
}
@@ -693,7 +693,7 @@ public:
class TypedInit : public Init {
RecTy *Ty;
public:
- TypedInit(RecTy *T) : Ty(T) {}
+ explicit TypedInit(RecTy *T) : Ty(T) {}
RecTy *getType() const { return Ty; }
@@ -719,7 +719,8 @@ public:
class VarInit : public TypedInit {
std::string VarName;
public:
- VarInit(const std::string &VN, RecTy *T) : TypedInit(T), VarName(VN) {}
+ explicit VarInit(const std::string &VN, RecTy *T)
+ : TypedInit(T), VarName(VN) {}
virtual Init *convertInitializerTo(RecTy *Ty) {
return Ty->convertValue(this);
@@ -807,7 +808,7 @@ public:
class DefInit : public Init {
Record *Def;
public:
- DefInit(Record *D) : Def(D) {}
+ explicit DefInit(Record *D) : Def(D) {}
virtual Init *convertInitializerTo(RecTy *Ty) {
return Ty->convertValue(this);