<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/56535>56535</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Clang aborts in parsing the register pointer array (bug report)
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          drzchen
      </td>
    </tr>
</table>

<pre>
    When I use GCC to compile the following code, the compilation succeeds and the result is correct.
However, when I use Clang 14.0.6, a compilation error is reported and the compilation aborts.
I believe it is a bug of Clang (likely in the parsing module), as `rq[0]` is not the address of a register variable, but the address of array `a`.
```c
#include <stdio.h>
int main()
{
  int a[10] = {0,1,2,3,4,5};
  register int *rq[2] = { a }; /* rq[0] = a */
  printf("%d\n", *(rq[0]+1)); /* print 1 */
  return 0;
}
```
Clang reports the error:
```
testClang.c:6:20: error: address of register variable requested
  printf("%d\n", *(rq[0]+1)); /* print 1 */
                   ^~
1 error generated.
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy1VMFymzAQ_Rpx0ZQRAoF94ODgpM0X9CzQgtUqyJFEPOnXdyWI4yS91uMdJHb37dsnLb1Vr-3PE8z0kS4e6Peuo8HSwT6dtQEaTkBHa4y96HnCtwoI79LbNUIGbWfql2EAUJ7KWSWnA7-YQLXHMOdgCDlhR8IOP-wFXsBFjMt7zc5IBC-qnOV1dMkP4OCcdRHKwdm6AOpa5TZK9ujzW5lH2oPRWInqRELSfpmoHbdKhO-M_g3mleo5AZ2l87G_J6sWgx3uEwtPSc3cMxF3jIgjriPUbENKkUphkz6CSmQ2aR_A0RfptOxNEqlfvkY6J18jqkTbuOJq_Q_bnpd6HsyigJKy80Fpm59Ieb969Rzok9QzthBprhnN3bqgNLolEi4iY8xHa5A97wo0jlaiVWiCNEdSXvOuDUQAwg-pa36DgU2uGeh9wAB61SVFyJgUPRve2SHQmEhiVaGI6Oa07NbA3bus_K5Igu9vwFM6LT6BOgiLmym78o6MPmq4btdTXq-LT2eQ7hApD_8MD-BDSskHDKnRONY4XJNuT_DLSeOb5wUBQP3X3r_8iLgnzXYpim1GJpjBSaTy-Wplqi3VvtzLLOhgoF0FWkcmzsDb_V9Hd-vwbJEIPrdLy3dxhlZRkXG2ONOeQjj7KGuk_jDpcFr6HKcSN8a8vD2-nZ39hd8A3GrvUSxciFqUIju1jFe7io_7UdY9F2MDcuxrVsphbMaKF3VmJI6yb1Ex1HCGC00QUU9xzHTLGeesKQTjrBIiHxslmGzqqmLVjldAKgY4LiaPPHLrpsy1iRL24tFpsFX_7pTe62kGSOUQXy7hZF2r3J8Bv1ZZKt0m6n8BdpaJcQ">