<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/78183>78183</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[clang] Parenthesized initialization of arrays does not work in new expression
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang:frontend
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
tomasz-kaminski-sonarsource
</td>
</tr>
</table>
<pre>
The parenthesized initialization of arrays (aggregates) is not supported in the new expression:
```C++
int main() {
int x[10](1, 2); // OK
auto p = new int[10](1, 2); // ERROR, accepted by GCC and MSVC
}
```
Live example: [Godbolt](https://godbolt.org/z/64K39oEhKl)
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyMkk-LnEAQxT9NeWlm0Gr_jAcP82fdwyZs2ITcS63Rzrbd0t3u7synDzoDIQuBQIFY5av3Sn7kveoNcwXZAbJTRHMYrKuCHclfN680KuNf1cZbQ87b2bUcNba7VD8GFhM5NmFgr67cCWVUUKTVlYKyRtizIOfo4gXgjvrecU-BPWAplBfGBuHnabIurFIRBhaG3wV_TI69V9aA3EN8gngPeXyrI-BhqbWrTBAjKQO4W3ZCce8LsUw-IDskMWQnwF0CeBQIWII8CAFYA9bi-en-Oc3BikmAPK3-yoR_Se_Kh5eX55elT23L0xK_uYjH41GQ6cTX7z-P99TF6VP82-sX9caCP2icNIPcC8gOj7ZrrA43yyGEyS-3r279bbS1rgesr4B1nj7J0j4MTxqwjLpKdqUsKeIqKeJMyjwvdtFQcSq5pRQpKWMkKoj5jHGexx2n3CQyUhXGmMZJkiW5LLJim6dIeYZleaaCmzNCGvNISm-1fhsX_0h5P3NV7JKdjDQ1rP0KDWKryfQg92dnTWDTAeKCkqsW6aaZew9prJUP_s-yoIJeobuJs5P49n80dZZv-Lxb97qQ8zc10ex09ekfqjDMzba1I2C9BLg_NpOzv7gNgPV6mges1-t-BwAA__-BjvJt">