[all-commits] [llvm/llvm-project] 50127a: [Clang] add typo correction for unknown attribute ...
Oleksandr T. via All-commits
all-commits at lists.llvm.org
Thu May 22 07:03:55 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 50127ac054a08321b64f4ac24bda5cad20e20ac1
https://github.com/llvm/llvm-project/commit/50127ac054a08321b64f4ac24bda5cad20e20ac1
Author: Oleksandr T. <oleksandr.tarasiuk at outlook.com>
Date: 2025-05-22 (Thu, 22 May 2025)
Changed paths:
M clang/docs/ReleaseNotes.rst
M clang/include/clang/Basic/AttributeCommonInfo.h
M clang/include/clang/Basic/Attributes.h
M clang/include/clang/Basic/CMakeLists.txt
M clang/include/clang/Basic/DiagnosticCommonKinds.td
A clang/include/clang/Basic/SimpleTypoCorrection.h
M clang/include/clang/Sema/Sema.h
M clang/lib/AST/CommentSema.cpp
M clang/lib/Basic/Attributes.cpp
M clang/lib/Basic/CMakeLists.txt
A clang/lib/Basic/SimpleTypoCorrection.cpp
M clang/lib/Sema/SemaDeclAttr.cpp
M clang/lib/Sema/SemaType.cpp
M clang/test/Parser/cxx0x-attributes.cpp
M clang/test/Sema/attr-c2x.c
M clang/test/Sema/unknown-attributes.c
M clang/test/SemaCXX/cxx11-gnu-attrs.cpp
M clang/utils/TableGen/ClangAttrEmitter.cpp
M clang/utils/TableGen/TableGen.cpp
M clang/utils/TableGen/TableGenBackends.h
Log Message:
-----------
[Clang] add typo correction for unknown attribute names (#140629)
This patch enhances Clang's diagnosis for unknown attributes by
providing typo correction suggestions for known attributes.
```cpp
[[gmu::deprected]] // expected-warning {{unknown attribute 'gmu::deprected' ignored; did you mean 'gnu::deprecated'?}}
int f1(void) {
return 0;
}
[[deprected]] // expected-warning {{unknown attribute 'deprected' ignored; did you mean 'deprecated'?}}
int f2(void) {
return 0;
}
```
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list