[Clang] accepts malformed attribute syntax [[X1(])]]
Open
accepts-invalid
c++11
c23
clang:frontend
confirmed
generated by fuzzer
- Dominant language
- LLVM
- Stars
- 40.5k
- Forks
- 18.7k
- PR merge metrics
- PR metrics pending
Description
The code contains malformed C++11 attribute syntax with mismatched brackets/parentheses: [[ X1 ( ] ) ] ] ;. GCC rejects it, but Clang accepts it.
Code:
```
[ [ X1 ( ] ) ] ] ;
```
See Compiler Explorer: [https://godbolt.org/z/Td6nrxW6z](https://godbolt.org/z/Td6nrxW6z)
Regression since Clang 6
The test case was generated by a fuzzer.
Contributor guide
Assessment
This issue has not been assessed yet.