[llvm] 17b7741 - Fix compilation of Any.h header.

Justin Lebar via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 12 08:26:36 PST 2020


Author: Justin Lebar
Date: 2020-02-12T08:25:14-08:00
New Revision: 17b77418121139c4e8cfb050d82ead3f29db7132

URL: https://github.com/llvm/llvm-project/commit/17b77418121139c4e8cfb050d82ead3f29db7132
DIFF: https://github.com/llvm/llvm-project/commit/17b77418121139c4e8cfb050d82ead3f29db7132.diff

LOG: Fix compilation of Any.h header.

In a previous patch I changed `std::decay<T>::type` to `std::decay<T>`
rather than `std::decay_t<T>`.  This seems to have broken the build
*only for clang-cl*.  I don't know why.

Submitting with post-commit review because this is an obvious fix for a
build breakage and we've verified that it fixes the breakage.

Added: 
    

Modified: 
    llvm/include/llvm/ADT/Any.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/ADT/Any.h b/llvm/include/llvm/ADT/Any.h
index 9d819841e3fc..0aded628cda4 100644
--- a/llvm/include/llvm/ADT/Any.h
+++ b/llvm/include/llvm/ADT/Any.h
@@ -74,7 +74,7 @@ class Any {
                     // adopting it to work-around usage of `Any` with types that
                     // need to be implicitly convertible from an `Any`.
                     llvm::negation<std::is_convertible<Any, std::decay_t<T>>>,
-                    std::is_copy_constructible<std::decay<T>>>::value,
+                    std::is_copy_constructible<std::decay_t<T>>>::value,
                 int> = 0>
   Any(T &&Value) {
     Storage =


        


More information about the llvm-commits mailing list