diff options
author | George Burgess IV <george.burgess.iv@gmail.com> | 2017-01-05 01:21:21 +0000 |
---|---|---|
committer | George Burgess IV <george.burgess.iv@gmail.com> | 2017-01-05 01:21:21 +0000 |
commit | be04bfee2a35bea91d0e64eb0dfc1c454ffc37e9 (patch) | |
tree | 09e98a7a4b905e5bf88d9e00530aab6f1a671dc6 | |
parent | 528600c41ffb6afc9d95f5ba808ed5e6b348d7a3 (diff) | |
download | bcm5719-llvm-be04bfee2a35bea91d0e64eb0dfc1c454ffc37e9.tar.gz bcm5719-llvm-be04bfee2a35bea91d0e64eb0dfc1c454ffc37e9.zip |
[Sema] Mark undefined ctors as deleted. NFC.
Looks like these functions exist just to prevent bad implicit
conversions. Rather than waiting for the linker to complain about
undefined references to them, we can mark them as deleted.
llvm-svn: 291058
-rw-r--r-- | clang/include/clang/Sema/Ownership.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/include/clang/Sema/Ownership.h b/clang/include/clang/Sema/Ownership.h index 92ea5296c45..fd46de870fb 100644 --- a/clang/include/clang/Sema/Ownership.h +++ b/clang/include/clang/Sema/Ownership.h @@ -153,8 +153,8 @@ namespace clang { ActionResult(const DiagnosticBuilder &) : Val(PtrTy()), Invalid(true) {} // These two overloads prevent void* -> bool conversions. - ActionResult(const void *); - ActionResult(volatile void *); + ActionResult(const void *) = delete; + ActionResult(volatile void *) = delete; bool isInvalid() const { return Invalid; } bool isUsable() const { return !Invalid && Val; } @@ -192,8 +192,8 @@ namespace clang { ActionResult(const DiagnosticBuilder &) : PtrWithInvalid(0x01) { } // These two overloads prevent void* -> bool conversions. - ActionResult(const void *); - ActionResult(volatile void *); + ActionResult(const void *) = delete; + ActionResult(volatile void *) = delete; bool isInvalid() const { return PtrWithInvalid & 0x01; } bool isUsable() const { return PtrWithInvalid > 0x01; } |