[clang] fc53bd6 - [clang] Replace call to private ctor with ElementCount::getScalable

Jonas Devlieghere via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 19 09:35:58 PDT 2020


Author: Jonas Devlieghere
Date: 2020-08-19T09:35:08-07:00
New Revision: fc53bd610ff95d2824617095bcf4976035b4cb9a

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

LOG: [clang] Replace call to private ctor with ElementCount::getScalable

Update the code for D86120 which made the constructors of `ElementCount`
private.

Added: 
    

Modified: 
    clang/lib/AST/ASTContext.cpp

Removed: 
    


################################################################################
diff  --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index c51629ecfd53..48ed637e737b 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -3714,7 +3714,7 @@ QualType ASTContext::getIncompleteArrayType(QualType elementType,
 ASTContext::BuiltinVectorTypeInfo
 ASTContext::getBuiltinVectorTypeInfo(const BuiltinType *Ty) const {
 #define SVE_INT_ELTTY(BITS, ELTS, SIGNED, NUMVECTORS)                          \
-  {getIntTypeForBitwidth(BITS, SIGNED), llvm::ElementCount(ELTS, true),        \
+  {getIntTypeForBitwidth(BITS, SIGNED), llvm::ElementCount::getScalable(ELTS), \
    NUMVECTORS};
 
 #define SVE_ELTTY(ELTTY, ELTS, NUMVECTORS)                                     \


        


More information about the cfe-commits mailing list