[clang] [OpenMP] Support capturing structured bindings in OpenMP regions. (PR #190832)

via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 7 12:31:50 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results

* 53508 tests passed
* 1075 tests skipped
* 6 tests failed

## Failed Tests
(click on a test name to see its output)

### Clang
<details>
<summary>Clang.CodeGenCXX/cxx20-decomposition.cpp</summary>

```
Exit Code: 2

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -std=c++20 -triple x86_64-linux-gnu -emit-llvm C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -std=c++20 -triple x86_64-linux-gnu -emit-llvm 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp' -o -
# .---command stderr------------
# | DeclRefExpr for Decl not entered in LocalDeclMap?
# | UNREACHABLE executed at C:\_work\llvm-project\llvm-project\clang\lib\CodeGen\CGExpr.cpp:3686!
# | PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script.
# | Stack dump:
# | 0.	Program arguments: c:\\_work\\llvm-project\\llvm-project\\build\\bin\\clang.exe -cc1 -internal-isystem C:\\_work\\llvm-project\\llvm-project\\build\\lib\\clang\\23\\include -nostdsysteminc -std=c++20 -triple x86_64-linux-gnu -emit-llvm C:\\_work\\llvm-project\\llvm-project\\clang\\test\\CodeGenCXX\\cxx20-decomposition.cpp -o -
# | 1.	<eof> parser at end of file
# | 2.	Per-file LLVM IR generation
# | 3.	C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp:10:10: Generating code for declaration 'f()::(lambda)::operator()'
# | Exception Code: 0xC000001D
# | fatal error: error in backend: IO sandbox violation
# `-----------------------------
# error: command failed with exit status: 70
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp'
# .---command stderr------------
# | FileCheck error: '<stdin>' is empty.
# | FileCheck command line:  c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\CodeGenCXX\cxx20-decomposition.cpp
# `-----------------------------
# error: command failed with exit status: 2

--

```
</details>
<details>
<summary>Clang.DebugInfo/CXX/lambda-capture-packs.cpp</summary>

```
Exit Code: 2

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -triple x86_64-pc-windows-gnu -emit-llvm    -debug-info-kind=standalone -std=c++26 C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp -o - | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -triple x86_64-pc-windows-gnu -emit-llvm -debug-info-kind=standalone -std=c++26 'C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp' -o -
# .---command stderr------------
# | DeclRefExpr for Decl not entered in LocalDeclMap?
# | UNREACHABLE executed at C:\_work\llvm-project\llvm-project\clang\lib\CodeGen\CGExpr.cpp:3686!
# | PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script.
# | Stack dump:
# | 0.	Program arguments: c:\\_work\\llvm-project\\llvm-project\\build\\bin\\clang.exe -cc1 -internal-isystem C:\\_work\\llvm-project\\llvm-project\\build\\lib\\clang\\23\\include -nostdsysteminc -triple x86_64-pc-windows-gnu -emit-llvm -debug-info-kind=standalone -std=c++26 C:\\_work\\llvm-project\\llvm-project\\clang\\test\\DebugInfo\\CXX\\lambda-capture-packs.cpp -o -
# | 1.	<eof> parser at end of file
# | 2.	Per-file LLVM IR generation
# | 3.	C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp:163:10: Generating code for declaration 'capture_binding_and_param_pack(int, int)::(lambda)::operator()'
# | Exception Code: 0xC000001D
# | fatal error: error in backend: IO sandbox violation
# `-----------------------------
# error: command failed with exit status: 70
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp'
# .---command stderr------------
# | FileCheck error: '<stdin>' is empty.
# | FileCheck command line:  c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\DebugInfo\CXX\lambda-capture-packs.cpp
# `-----------------------------
# error: command failed with exit status: 2

--

```
</details>
<details>
<summary>Clang.SemaCXX/cxx1z-constexpr-lambdas.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -std=c++1z -verify -fsyntax-only -fblocks C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp -fcxx-exceptions
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -std=c++1z -verify -fsyntax-only -fblocks 'C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp' -fcxx-exceptions
# .---command stderr------------
# | error: 'expected-warning' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp Line 387 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp:389): captured structured bindings are a C++20 extension
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp Line 398 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp:400): captured structured bindings are a C++20 extension
# | error: 'expected-note' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp Line 386 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp:390): 'key' declared here
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp Line 397 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-constexpr-lambdas.cpp:401): 'key' declared here
# | 4 errors generated.
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>Clang.SemaCXX/cxx1z-decomposition.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -std=c++17 -Wc++20-extensions -verify=expected C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -std=c++17 -Wc++20-extensions -verify=expected 'C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp'
# .---command stderr------------
# | error: 'expected-warning' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 76: C++20
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 77: C++20
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 90: C++20
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 99: C++20
# | error: 'expected-note' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 70: 'n' declared here
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 70: 'n' declared here
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 88: 'bit' declared here
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\cxx1z-decomposition.cpp Line 88: 'bit' declared here
# | 8 errors generated.
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>Clang.SemaCXX/decomposition-blocks.cpp</summary>

```
Exit Code: 70

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -std=c++17 -fsyntax-only -verify C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp -fblocks
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -std=c++17 -fsyntax-only -verify 'C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp' -fblocks
# .---command stderr------------
# | Assertion failed: isa<To>(Val) && "cast<Ty>() argument of incompatible type!", file C:\_work\llvm-project\llvm-project\llvm\include\llvm/Support/Casting.h, line 572
# | PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script.
# | Stack dump:
# | 0.	Program arguments: c:\\_work\\llvm-project\\llvm-project\\build\\bin\\clang.exe -cc1 -internal-isystem C:\\_work\\llvm-project\\llvm-project\\build\\lib\\clang\\23\\include -nostdsysteminc -std=c++17 -fsyntax-only -verify C:\\_work\\llvm-project\\llvm-project\\clang\\test\\SemaCXX\\decomposition-blocks.cpp -fblocks
# | 1.	C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp:13:4: current parser token ')'
# | 2.	C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp:9:13: parsing function body 'test'
# | 3.	C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp:9:13: in compound statement ('{}')
# | 4.	C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-blocks.cpp:11:7: block literal parsing
# | Exception Code: 0xC000001D
# `-----------------------------
# error: command failed with exit status: 70

--

```
</details>
<details>
<summary>Clang.SemaCXX/decomposition-openmp.cpp</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 1
c:\_work\llvm-project\llvm-project\build\bin\clang.exe -cc1 -internal-isystem C:\_work\llvm-project\llvm-project\build\lib\clang\23\include -nostdsysteminc -fsyntax-only -verify -std=c++20 -fopenmp C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\clang.exe' -cc1 -internal-isystem 'C:\_work\llvm-project\llvm-project\build\lib\clang\23\include' -nostdsysteminc -fsyntax-only -verify -std=c++20 -fopenmp 'C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp'
# .---command stderr------------
# | error: 'expected-error' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp Line 30 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp:29): capturing a structured binding is not yet supported in OpenMP
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp Line 30 (directive at C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp:29): capturing a structured binding is not yet supported in OpenMP
# | error: 'expected-note' diagnostics expected but not seen: 
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp Line 26: declared here
# |   File C:\_work\llvm-project\llvm-project\clang\test\SemaCXX\decomposition-openmp.cpp Line 26: declared here
# | 4 errors generated.
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

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


More information about the cfe-commits mailing list