aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-readobj/llvm-readobj.cpp
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2021-01-26 19:51:22 -0800
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2021-01-28 15:07:27 -0800
commit17c584551d573f1693990773e29fbe6b4b6fa4f4 (patch)
treefe37898bc8a7db70b9da9de3fe01622b42f93d8d /llvm/tools/llvm-readobj/llvm-readobj.cpp
parente056fc6cb676f72d5b7dfe7ca540b3275bd1a46f (diff)
downloadllvm-17c584551d573f1693990773e29fbe6b4b6fa4f4.zip
llvm-17c584551d573f1693990773e29fbe6b4b6fa4f4.tar.gz
llvm-17c584551d573f1693990773e29fbe6b4b6fa4f4.tar.bz2
ADT: Add SFINAE to the generic IntrusiveRefCntPtr constructors
Add an `enable_if` to the generic `IntrusiveRefCntPtr` constructors so that std::is_convertible gives an honest answer when the underlying pointers cannot be converted. Added `static_assert`s to the test suite to verify. Also combine generic constructors from `IntrusiveRefCntPtr<X>&&` and `const IntrusiveRefCntPtr<X>&`. At first glance this appears to be an infinite loop, but the real copy/move constructors are spelled out separately above. Added a unit test to verify. Differential Revision: https://reviews.llvm.org/D95498
Diffstat (limited to 'llvm/tools/llvm-readobj/llvm-readobj.cpp')
0 files changed, 0 insertions, 0 deletions