================
@@ -851,6 +851,50 @@ class ScanfDiagnosticFormatHandler
}
};
+/// `I` points to the next character of `%p` format.
+/// This functon checks if the subsequent character can be linux kernel's
+/// extnded format specifier
+static inline constexpr bool canBeLinuxFormatExtension(const char *I,
+ const char *E) {
+ assert(I < E && "format string not yet exhausted");
+ // Kernel Document: https://docs.kernel.org/core-api/printk-formats.html
+ switch (*I) {
----------------
nickdesaulniers wrote:
The URL with anchor
https://docs.kernel.org/core-api/printk-formats.html#pointer-types may be more
precise to use in the comment.
https://github.com/llvm/llvm-project/pull/65969
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits