================ @@ -0,0 +1,64 @@ +// Verify that -mloadtime-comment-vars= diagnoses named C variables it cannot +// preserve. The diagnostics are produced by Sema and fire even with +// -fsyntax-only. +// +// Covered cases: +// - volatile-qualified pointer (char *volatile) +// - pointer-to-volatile character (volatile char *) +// - volatile character array (volatile char[]) +// - thread-local variable (__thread, not static storage duration) +// - pointer not initialized directly with a string literal +// - name-matched variables of an unsupported type (int, unsigned char) +// - valid const char array — no diagnostic +// - a preserved variable counts as used: no -Wunused-const-variable for it, +// while an unlisted static const variable still warns ---------------- hubert-reinterpretcast wrote:
Function local static _is_ covered but not listed here. https://github.com/llvm/llvm-project/pull/187986 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
