forked from OSchip/llvm-project
Add additional test coverage for C2x N2508
This spotted a mistake with the original patch, so it puts the status
back to "partial" in the C status tracking page.
This amends 510383626f
.
This commit is contained in:
parent
8206044183
commit
a244194f73
|
@ -0,0 +1,22 @@
|
|||
// RUN: %clang_cc1 -verify -std=c2x %s
|
||||
|
||||
/* WG14 N2508: partial
|
||||
* Free positioning of labels inside compound statements
|
||||
*/
|
||||
void test() {
|
||||
{
|
||||
inner:
|
||||
}
|
||||
|
||||
switch (1) {
|
||||
// FIXME: this should be accepted per C2x 6.8.2p2.
|
||||
case 1: // expected-error {{label at end of switch compound statement: expected statement}}
|
||||
}
|
||||
|
||||
{
|
||||
multiple: labels: on: a: line:
|
||||
}
|
||||
|
||||
final:
|
||||
}
|
||||
|
|
@ -763,7 +763,13 @@ conformance.</p>
|
|||
<tr>
|
||||
<td>Free positioning of labels inside compound statements</td>
|
||||
<td><a href="https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2508.pdf">N2508</a></td>
|
||||
<td class="unreleased" align="center">Clang 16</td>
|
||||
<td class="partial" align="center">
|
||||
<details><summary>Partial</summary>
|
||||
Clang supports labels at the end of compound statements but does
|
||||
not yet support <code>case</code> or <code>default</code> labels at
|
||||
the end of a switch statement's compound block.
|
||||
</details>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Clarification request for C17 example of undefined behavior</td>
|
||||
|
|
Loading…
Reference in New Issue