From: Stephen Kelly Date: Sun, 2 Dec 2018 16:36:23 +0000 (+0000) Subject: Add dump tests for ArrayInitLoopExpr and ArrayInitIndexExpr X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7b954aa8b885e87b8a95738c9545e3e32dd31a13;p=clang Add dump tests for ArrayInitLoopExpr and ArrayInitIndexExpr git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@348093 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/AST/ast-dump-array.cpp b/test/AST/ast-dump-array.cpp new file mode 100644 index 0000000000..303b86b0d3 --- /dev/null +++ b/test/AST/ast-dump-array.cpp @@ -0,0 +1,10 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-unknown -ast-dump %s | FileCheck -strict-whitespace %s + +void testArrayInitExpr() +{ + int a[10]; + auto l = [a]{ + }; + // CHECK: |-ArrayInitLoopExpr 0x{{[^ ]*}} 'int [10]' + // CHECK: | `-ArrayInitIndexExpr 0x{{[^ ]*}} <> 'unsigned long' +}