summaryrefslogtreecommitdiffstats
path: root/lld/include/lld
diff options
context:
space:
mode:
authorRui Ueyama <ruiu@google.com>2017-12-07 03:24:57 +0000
committerRui Ueyama <ruiu@google.com>2017-12-07 03:24:57 +0000
commitc0081639cca7aff66236bbfd41abb1739b499438 (patch)
tree72b9d5c5577b19bbcaf74cd5c8b2fe7f04ddb2c6 /lld/include/lld
parent31de2f0ccf4b616f595cef9b6181ce86ea419527 (diff)
downloadbcm5719-llvm-c0081639cca7aff66236bbfd41abb1739b499438.tar.gz
bcm5719-llvm-c0081639cca7aff66236bbfd41abb1739b499438.zip
Remove checkToString functions and use toString instead.
Differential Revision: https://reviews.llvm.org/D40928 llvm-svn: 320005
Diffstat (limited to 'lld/include/lld')
-rw-r--r--lld/include/lld/Common/ErrorHandler.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/lld/include/lld/Common/ErrorHandler.h b/lld/include/lld/Common/ErrorHandler.h
index 5f544b88155..8ae6f46ac59 100644
--- a/lld/include/lld/Common/ErrorHandler.h
+++ b/lld/include/lld/Common/ErrorHandler.h
@@ -102,12 +102,10 @@ T check2(Expected<T> E, llvm::function_ref<std::string()> Prefix) {
return std::move(*E);
}
-inline std::string checkToString(const Twine &S) { return S.str(); }
-inline std::string checkToString(std::string S) { return S; }
-inline std::string checkToString(const char *S) { return S; }
+inline std::string toString(const Twine &S) { return S.str(); }
// To evaluate the second argument lazily, we use C macro.
-#define CHECK(E, S) check2(E, [&] { return checkToString(S); })
+#define CHECK(E, S) check2(E, [&] { return toString(S); })
} // namespace lld
OpenPOWER on IntegriCloud