summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Option
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Option')
-rw-r--r--llvm/lib/Option/Arg.cpp2
-rw-r--r--llvm/lib/Option/ArgList.cpp2
-rw-r--r--llvm/lib/Option/Option.cpp2
3 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/Option/Arg.cpp b/llvm/lib/Option/Arg.cpp
index c3de2d1a496..3e8a1d80231 100644
--- a/llvm/lib/Option/Arg.cpp
+++ b/llvm/lib/Option/Arg.cpp
@@ -61,7 +61,9 @@ void Arg::print(raw_ostream& O) const {
O << "]>\n";
}
+#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
LLVM_DUMP_METHOD void Arg::dump() const { print(dbgs()); }
+#endif
std::string Arg::getAsString(const ArgList &Args) const {
SmallString<256> Res;
diff --git a/llvm/lib/Option/ArgList.cpp b/llvm/lib/Option/ArgList.cpp
index f94de866ef3..7ff358a57e0 100644
--- a/llvm/lib/Option/ArgList.cpp
+++ b/llvm/lib/Option/ArgList.cpp
@@ -353,7 +353,9 @@ void ArgList::print(raw_ostream &O) const {
}
}
+#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
LLVM_DUMP_METHOD void ArgList::dump() const { print(dbgs()); }
+#endif
//
diff --git a/llvm/lib/Option/Option.cpp b/llvm/lib/Option/Option.cpp
index 5eb179fbd25..736b939fe80 100644
--- a/llvm/lib/Option/Option.cpp
+++ b/llvm/lib/Option/Option.cpp
@@ -83,7 +83,9 @@ void Option::print(raw_ostream &O) const {
O << ">\n";
}
+#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
LLVM_DUMP_METHOD void Option::dump() const { print(dbgs()); }
+#endif
bool Option::matches(OptSpecifier Opt) const {
// Aliases are never considered in matching, look through them.
OpenPOWER on IntegriCloud