[clang] [Sema] Fix crash on invalid code with parenthesized aggregate initialization (PR #76232)

Vladimir Vereschaka via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 22 12:22:15 PST 2023


vvereschaka wrote:

these changes break the libc++ tests - `llvm-libc++-static.cfg.in::transform_error.mandates.verify.cpp`

```
# .---command stderr------------
# | error: 'expected-error' diagnostics expected but not seen: 
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:49): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:53): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:61): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:63): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:70): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:72): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:79): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# |   File * Line * (directive at C:\buildbot\as-builder-2\x-aarch64\llvm-project\libcxx\test\libcxx\utilities\expected\expected.void\transform_error.mandates.verify.cpp:81): {{(excess elements in struct initializer|no matching constructor for initialization of)}}{{.*}}
# | 8 errors generated.
# `-----------------------------
# error: command failed with exit status: 1

```

https://lab.llvm.org/buildbot/#/builders/119/builds/16381
https://lab.llvm.org/buildbot/#/builders/60/builds/15226

https://github.com/llvm/llvm-project/pull/76232


More information about the cfe-commits mailing list