[PATCH] D151040:  [NFC][CLANG] Fix static code analyzer concerns
    Soumi Manna via Phabricator via cfe-commits 
    cfe-commits at lists.llvm.org
       
    Tue May 23 07:42:54 PDT 2023
    
    
  
This revision was automatically updated to reflect the committed changes.
Closed by commit rG64e9ba7048b8: [NFC][CLANG] Fix static code analyzer concerns (authored by Manna).
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D151040/new/
https://reviews.llvm.org/D151040
Files:
  clang/lib/AST/ExprConstant.cpp
Index: clang/lib/AST/ExprConstant.cpp
===================================================================
--- clang/lib/AST/ExprConstant.cpp
+++ clang/lib/AST/ExprConstant.cpp
@@ -10174,6 +10174,8 @@
   if (!EvaluateLValue(E->getSubExpr(), Array, Info))
     return false;
 
+  assert(ArrayType && "unexpected type for array initializer");
+
   // Get a pointer to the first element of the array.
   Array.addArray(Info, E, ArrayType);
 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151040.524712.patch
Type: text/x-patch
Size: 438 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230523/5e29537e/attachment.bin>
    
    
More information about the cfe-commits
mailing list