ChenMiaoi wrote:
> The fix is correct, but while you’re at it, could you look at the other
> pragmas in here and see if there are any that call `getIdentifierInfo()` w/o
> checking whether we actually have an identifier? E.g. this also crashes (w/
> `-fms-compatibility`):
>
> ```c
> #pragma strict_gs_check (_Pragma("weak foobar"))
> ```
>
> `_Pragma("weak foobar")` seems to be a reliable way of producing an
> annotation token pretty much irrespective of where it appears, so I’d just
> look at the code and see what happens if you put that in a place where we
> call `getIdentifierInfo()` but don’t check the token kind before that
I'll check the other pragmas for similar issues. If I find multiple places that
need fixing, would you prefer a single commit or separate commits?
https://github.com/llvm/llvm-project/pull/228990
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits