aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/StackProtector.cpp
diff options
context:
space:
mode:
authorJerin Philip <jerinphilip@live.in>2023-11-07 18:57:41 +0530
committerGitHub <noreply@github.com>2023-11-07 08:27:41 -0500
commit2e7913342eb9d5cd1744d4c24e1898588429b80d (patch)
treeef3ecf2ae36445e375d5cbe0388cd7422e1dbb6e /llvm/lib/CodeGen/StackProtector.cpp
parenta0303d89239ca143664c4a5df45cb9cf9f4fa643 (diff)
downloadllvm-2e7913342eb9d5cd1744d4c24e1898588429b80d.zip
llvm-2e7913342eb9d5cd1744d4c24e1898588429b80d.tar.gz
llvm-2e7913342eb9d5cd1744d4c24e1898588429b80d.tar.bz2
[clang] Improve `_Alignas` on a `struct` declaration diagnostic (#65638)
Fixes https://github.com/llvm/llvm-project/issues/58637. Adds `isAlignas()` method on `AttributeCommonInfo` which accounts for C++ `alignas` as well as C11 `_Alignas`. The method is used to improve diagnostic in C when `_Alignas` is used in C at the wrong location. This corrects the previously suggested move of `_Alignas` past the declaration specifier, now warns attribute `_Alignas` is ignored. Based on https://reviews.llvm.org/D141177.
Diffstat (limited to 'llvm/lib/CodeGen/StackProtector.cpp')
0 files changed, 0 insertions, 0 deletions