llvm-project/clang/test/FixIt
Corentin Jabot c92056d038 [Clang][C++23] P2071 Named universal character escapes
Implements [[ https://wg21.link/p2071r1  | P2071 Named Universal Character Escapes ]] - as an extension in all language mode, the patch  not warn in c++23 mode will be done later once this paper is plenary approved (in July).

We add

 * A code generator that transforms `UnicodeData.txt` and `NameAliases.txt` to a space efficient data structure that can be queried in `O(NameLength)`
 * A set of functions in `Unicode.h` to query that data, including

   * A function to find an exact match of a given Unicode character name
   * A function to perform a loose (ignoring case, space, underscore, medial hyphen) matching
   * A function returning the best matching codepoint for a given string per edit distance

 * Support of `\N{}` escape sequences in String and character Literals, with loose and typos diagnostics/fixits
 * Support of `\N{}` as UCN with loose matching diagnostics/fixits.

Loose matching is considered an error to match closely the semantics of P2071.

The generated data contributes to 280kB of data to the binaries.

`UnicodeData.txt` and `NameAliases.txt`  are not committed to the repository in this patch, and regenerating the data is a manual process.

Reviewed By: tahonermann

Differential Revision: https://reviews.llvm.org/D123064
2022-06-25 19:03:33 +02:00
..
Inputs
atomic-property.m
auto-fixit.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
auto-isa-fixit.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
bridge-cast-in-arc.mm
bridge-in-non-arc.m
dereference-addressof.c
fixit-add-synthesize-to-property.m
fixit-autoreleasepool.m
fixit-availability-maccatalyst.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-availability.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-availability.mm
fixit-c++2a.cpp
fixit-c++11.cpp [clang] [C++2b] [P1102] Accept lambdas without parameter list (). 2021-03-24 14:42:27 +01:00
fixit-c90.c
fixit-class-method-messaging.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-cxx-init-order.cpp [clang] Add fixit for Wreorder-ctor 2021-03-24 19:22:53 +00:00
fixit-cxx1y-compat.cpp
fixit-cxx11-attributes.cpp
fixit-cxx11-compat.cpp
fixit-eof-space.c
fixit-errors-1.c
fixit-errors.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-format-darwin.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-format-ios-nopedantic.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-format-ios.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-function-call.cpp
fixit-include.c
fixit-include.h
fixit-interface-as-param.m
fixit-large-file.cpp
fixit-missing-method-return-type.m
fixit-missing-self-in-block.m
fixit-multiple-selector-warnings.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-newline-style.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-nsstring-compare.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-nullability-declspec.cpp
fixit-objc-arc.m
fixit-objc-bridge-related-attr.m
fixit-objc-bridge-related-property.m
fixit-objc-bridge-related.m
fixit-objc-direct.m
fixit-objc-message-comma-separator.m
fixit-objc-message.m
fixit-objc-missing-method-impl.m Reland "[clang][ObjC] Add fix it for missing methods in impl" 2022-01-06 10:55:02 -05:00
fixit-objc.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-pmem.cpp
fixit-pragma-attribute.c [Clang] Support multiple attributes in a single pragma 2022-03-18 12:20:41 +00:00
fixit-pragma-attribute.cpp [Clang] Support multiple attributes in a single pragma 2022-03-18 12:20:41 +00:00
fixit-pragma-pack.c
fixit-recompile.c
fixit-recursive-block.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-static-assert.cpp
fixit-static-object-decl.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-suffix.c
fixit-typedef-instead-of-typename-typo.cpp
fixit-unicode-named-escape-sequences.c [Clang][C++23] P2071 Named universal character escapes 2022-06-25 19:03:33 +02:00
fixit-unicode-with-utf8-output.c
fixit-unicode.c Implement P1949 2021-08-18 07:33:14 -04:00
fixit-uninit.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
fixit-unrecoverable.c
fixit-unrecoverable.cpp
fixit-unused-lambda-capture.cpp
fixit-vexing-parse-cxx0x.cpp
fixit-vexing-parse.cpp
fixit.c Change the behavior of implicit int diagnostics 2022-05-04 08:35:47 -04:00
fixit.cpp [clang] Stop providing builtin overload candidate for relational function pointer comparisons 2021-06-26 00:08:02 +02:00
format-darwin.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
format-no-fixit.m
format.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
format.mm
member-mismatch.cpp [Sema] Add FixIt when a C++ out-of-line method has extra/missing const 2021-12-15 14:30:54 +01:00
messages.cpp
multiarg-selector-fixit.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
no-diagnostics-fixit-info.c
no-fixit.cpp
no-macro-fixit.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
no-typo.c
nullability.mm
objc-literals.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
property-access-fixit.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
selector-fixit.m
typo-crash.cpp
typo-crash.m
typo-location-bugs.cpp
typo-using.cpp
typo.c Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00
typo.cpp
typo.m Use functions with prototypes when appropriate; NFC 2022-02-09 17:16:10 -05:00