… and. -Wcompound-token-split-by-space
Clang has 6 messages for this flag.
- Code
-Wcompound-token-split-by-space- Severity
- warning
- Message
{} and- Message
introducing statement expression- Message
terminating statement expression- Message
introducing attribute- Message
terminating attribute- Message
forming pointer to member type
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wconditional-type-mismatch- Severity
- warning
- Message
pointer/integer type mismatch in conditional expression- Message
({} and {})
Clang has 3 messages for this flag.
- Code
-Wconditional-uninitialized- Severity
- warning
- Message
variable {} may be uninitialized when- Message
used here- Message
captured by block
Clang enables it by default. Clang has 4 messages for this flag.
- Code
-Wconfig-macros- Severity
- warning
- Message
definition- Message
#undef- Message
-D{}=…- Message
-U{}
Clang enables it by default. It also controls -Wbitfield-constant-conversion, -Wobjc-bool-constant-conversion.
- Code
-Wconstant-conversion- Severity
- warning
- Message
implicit conversion from {} to {} changes value from {} to {}
Clang enables it by default.
- Code
-Wconstant-evaluated- Severity
- warning
- Message
‘{}’ will always evaluate to ‘true’ in a manifestly constant-evaluated expression
Clang enables it by default.
- Code
-Wconstant-logical-operand- Severity
- warning
- Message
use of logical ‘{}’ with constant operand
Clang enables it by default.
- Code
-Wconstexpr-not-const- Severity
- warning
- Message
‘constexpr’ non-static member function will not be implicitly ‘const’ in C++14; add ‘const’ to avoid a change in behavior
Clang has 8 messages for this flag.
- Code
-Wconsumed- Severity
- warning
- Message
consumed analysis attribute is attached to member of class {} which isn’t marked as consumable- Message
state of variable ‘{}’ must match at the entry and exit of loop- Message
parameter ‘{}’ not in expected state when the function returns: expected ‘{}’, observed ‘{}’- Message
argument not in expected state; expected ‘{}’, observed ‘{}’- Message
return state set for an unconsumable type ‘{}’- Message
return value not in expected state; expected ‘{}’, observed ‘{}’- Message
invalid invocation of method ‘{}’ on object ‘{}’ while it is in the ‘{}’ state- Message
invalid invocation of method ‘{}’ on a temporary object while it is in the ‘{}’ state
Clang enables some of the diagnostics that it controls by default. It also controls -Wbitfield-enum-conversion, -Wbool-conversion, -Wcharacter-conversion, -Wconstant-conversion, -Wenum-conversion, -Wfloat-conversion, -Wimplicit-float-conversion, -Wimplicit-int-conversion, -Wint-conversion, -Wliteral-conversion, -Wnon-literal-null-conversion, -Wnull-conversion and 4 more. Clang has 5 messages for this flag.
- Code
-Wconversion- Severity
- warning
- Message
implicit conversion discards imaginary component: {} to {}- Message
implicit conversion turns vector to scalar: {} to {}- Message
passing non-generic address space pointer to {} may cause dynamic conversion affecting performance- Message
non-type template argument with value ‘{}’ converted to ‘{}’ for unsigned template parameter of type {}- Message
non-type template argument value ‘{}’ truncated to ‘{}’ for template parameter of type {}
- Code
-Wconversion-null- Severity
- warning
Clang enables it by default.
- Code
-Wcoro-non-aligned-allocation-function- Severity
- warning
- Message
under -fcoro-aligned-allocation, the non-aligned allocation function for the promise type {} has higher precedence than the global aligned allocation function
Clang enables it by default.
- Code
-Wcoro-type-aware-allocation-function- Severity
- warning
- Message
type aware {} will not be used for coroutine allocation
Clang enables it by default. It also controls -Walways-inline-coroutine, -Wcoro-non-aligned-allocation-function, -Wcoro-type-aware-allocation-function, -Wcoroutine-missing-unhandled-exception, -Wdeprecated-coroutine.
- Code
-Wcoroutine- Severity
- warning
- Message
return type of ‘coroutine_handle<>::address should be ‘void*’ (have {}) in order to get capability with existing async C API
Clang enables it by default.
- Code
-Wcoroutine-missing-unhandled-exception- Severity
- warning
- Message
{} is required to declare the member ‘unhandled_exception()’ when exceptions are enabled
Clang enables it by default.
- Code
-Wcoroutines-unsupported-target- Severity
- warning
- Message
coroutines are not currently supported on the 32-bit x86 Microsoft ABI
- Code
-Wcounter-extension- Severity
- warning
- Message
‘__COUNTER__’ is a C2y extension
- Code
-Wcovered-switch-default- Severity
- warning
- Message
default label in switch which covers all enumeration values
- Code
-Wcpp- Severity
- warning
Clang has 5 messages for this flag.
- Code
-Wcstring-format-directive- Severity
- warning
- Message
using {} directive in- Message
NSString- Message
CFString- Message
method- Message
CFfunction
- Code
-Wctad-maybe-unsupported- Severity
- warning
- Message
{} may not intend to support class template argument deduction
- Code
-Wctor-dtor-privacy- Severity
- warning
Clang enables it by default. Clang has 5 messages for this flag.
- Code
-Wctu- Severity
- warning
- Message
import of an external symbol for CTU failed: {}- Message
imported AST from ‘{}’ had been generated for a different language, current: {}, imported: {}- Message
imported AST from ‘{}’ had been generated for a different target, current: {}, imported: {}- Message
invocation for ‘{}’ is missing in the invocation list- Message
multiple invocations for ‘{}’ are found in the invocation list
Clang enables some of the diagnostics that it controls by default. Clang has 5 messages for this flag.
- Code
-Wcuda-compat- Severity
- warning
- Message
{} attribute parameter {} is negative and will be ignored- Message
nvcc does not allow ‘__{}__’ to appear after the parameter list in lambdas- Message
ignored ‘inline’ attribute on kernel function {}- Message
kernel function {} is a member function; this may not be accepted by nvcc- Message
argument to ‘#pragma unroll’ should not be in parentheses in CUDA C/C++
Clang has 3 messages for this flag.
- Code
-Wcustom-atomic-properties- Severity
- warning
- Message
atomic by default property {} has a user defined- Message
getter- Message
setter
Clang enables it by default. Clang has 3 messages for this flag.
- Code
-Wcxx-attribute-extension- Severity
- warning
- Message
ISO C++ does not allow- Message
an attribute list- Message
{}
Clang enables it by default. It also controls -Wdangling-assignment, -Wdangling-assignment-gsl, -Wdangling-capture, -Wdangling-field, -Wdangling-gsl, -Wdangling-initializer-list, -Wreturn-stack-address. Clang has 11 messages for this flag.
- Code
-Wdangling- Severity
- warning
- Message
temporary- Message
whose address is used as value of- Message
implicitly- Message
reference- Message
local- Message
variable- Message
reference- Message
array backing
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdangling-assignment- Severity
- warning
- Message
object backing- Message
the pointer
Clang enables it by default.
- Code
-Wdangling-assignment-gsl- Severity
- warning
- Message
object backing the pointer {} will be destroyed at the end of the full-expression
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdangling-capture- Severity
- warning
- Message
object whose reference is captured by {} will be destroyed at the end of the full-expression- Message
object whose reference is captured will be destroyed at the end of the full-expression
Clang enables it by default.
- Code
-Wdangling-else- Severity
- warning
- Message
add explicit braces to avoid dangling else
Clang enables it by default. Clang has 12 messages for this flag.
- Code
-Wdangling-field- Severity
- warning
- Message
binding reference member {} to stack allocated- Message
variable- Message
parameter- Message
reference- Message
backing array for ‘std::initializer_list’- Message
subobject of- Message
binds to- Message
is
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdangling-gsl- Severity
- warning
- Message
object backing the pointer will be destroyed at the end of the full-expression- Message
initializing pointer member {} to point to a temporary object whose lifetime is shorter than the lifetime of the constructed object
Clang enables it by default. Clang has 3 messages for this flag.
- Code
-Wdangling-initializer-list- Severity
- warning
- Message
array backing- Message
initializer list subobject of the allocated object- Message
the allocated initializer list
Clang enables it by default.
- Code
-Wdarwin-sdk-settings- Severity
- warning
- Message
SDK settings were ignored as ‘SDKSettings.json’ could not be parsed
- Code
-Wdate-time- Severity
- warning
- Message
expansion of date or time macro is not reproducible
Clang enables it by default.
- Code
-Wdealloc-in-category- Severity
- warning
- Message
-dealloc is being overridden in a category
Clang enables it by default.
- Code
-Wdebug-compression-unavailable- Severity
- warning
- Message
cannot compress debug sections ({} not enabled)
Clang has 2 messages for this flag.
- Code
-Wdeclaration-after-statement- Severity
- warning
- Message
mixing declarations and code is a C99 extension- Message
mixing declarations and code is incompatible with standards before C99
- Code
-Wdecls-in-multiple-modules- Severity
- warning
- Message
declaration {} is detected to be defined in multiple module units, first is from ‘{}’ and second is from ‘{}’; the compiler may not be good at merging the definitions.
Clang enables some of the diagnostics that it controls by default. It also controls -Wdefault-const-init-field, -Wdefault-const-init-unsafe, -Wdefault-const-init-var.
- Code
-Wdefault-const-init- Severity
- warning
- Code
-Wdefault-const-init-field- Severity
- warning
- Message
default initialization of an object of type {} with const member is incompatible with C++
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdefault-const-init-field-unsafe- Severity
- warning
- Message
default initialization of an object of type {} with const member leaves the object uninitialized- Message
and is incompatible with C++
Clang enables it by default. It also controls -Wdefault-const-init-field-unsafe, -Wdefault-const-init-var-unsafe.
- Code
-Wdefault-const-init-unsafe- Severity
- warning
- Code
-Wdefault-const-init-var- Severity
- warning
- Message
default initialization of an object of type {} is incompatible with C++
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdefault-const-init-var-unsafe- Severity
- warning
- Message
default initialization of an object of type {} leaves the object uninitialized- Message
and is incompatible with C++
Clang enables it by default. Clang has 17 messages for this flag.
- Code
-Wdefaulted-function-deleted- Severity
- warning
- Message
explicitly defaulted- Message
<ERROR>- Message
equality- Message
three-way- Message
equality- Message
relational- Message
explicitly defaulted- Message
default constructor
Clang enables it by default.
- Code
-Wdelayed-template-parsing-in-cxx20- Severity
- warning
- Message
-fdelayed-template-parsing is deprecated after C++20
- Code
-Wdelegating-ctor-cycles- Severity
- error
- Message
constructor for {} creates a delegation cycle
Delete. -Wdelete-abstract-non-virtual-dtor
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdelete-abstract-non-virtual-dtor- Severity
- warning
- Message
delete- Message
destructor
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdelete-incomplete- Severity
- warning
- Message
cannot delete expression with pointer-to-‘void’ type {}- Message
deleting pointer to incomplete type {} is incompatible with C++2c and may cause undefined behavior
Delete. -Wdelete-non-abstract-non-virtual-dtor
Clang has 2 messages for this flag.
- Code
-Wdelete-non-abstract-non-virtual-dtor- Severity
- warning
- Message
delete- Message
destructor
Clang enables some of the diagnostics that it controls by default. It also controls -Wdelete-abstract-non-virtual-dtor, -Wdelete-non-abstract-non-virtual-dtor.
- Code
-Wdelete-non-virtual-dtor- Severity
- warning
Delimited. -Wdelimited-escape-sequence-extension
Clang has 5 messages for this flag.
- Code
-Wdelimited-escape-sequence-extension- Severity
- warning
- Message
delimited- Message
named- Message
C++23- Message
C2y- Message
Clang
Clang enables it by default.
- Code
-Wdeprecate-lax-vec-conv-all- Severity
- warning
- Message
implicit conversion between vector types (’{}’ and ‘{}’) is deprecated; in the future, the behavior implied by ‘-fno-lax-vector-conversions’ will be the default
Clang enables some of the diagnostics that it controls by default. It also controls -Wdeprecated-anon-enum-enum-conversion, -Wdeprecated-array-compare, -Wdeprecated-attributes, -Wdeprecated-builtins, -Wdeprecated-comma-subscript, -Wdeprecated-copy, -Wdeprecated-copy-with-dtor, -Wdeprecated-declarations, -Wdeprecated-dynamic-exception-spec, -Wdeprecated-enum-compare, -Wdeprecated-enum-compare-conditional, -Wdeprecated-enum-enum-conversion and 13 more. Clang has 12 messages for this flag.
- Code
-Wdeprecated- Severity
- warning
- Message
-O4 is equivalent to -O3- Message
access declarations are deprecated; use using declarations instead- Message
argument ‘{}’ is deprecated- Message
, use ‘{}’ instead- Message
argument ‘{}’ is deprecated, {}- Message
treating ‘{}’ input as ‘{}’ when in C++ mode, this behavior is deprecated- Message
‘default’ clause for ‘metadirective’ is deprecated; use ‘otherwise’ instead- Message
‘depend’ clause for ‘ordered’ is deprecated; use ‘doacross’ instead
Clang enables it by default.
- Code
-Wdeprecated-altivec-src-compat- Severity
- warning
- Message
current handling of vector bool and vector pixel types in this context are deprecated; the default behaviour will soon change to that implied by the ‘-altivec-compat=xl’ option
Arithmetic between. -Wdeprecated-anon-enum-enum-conversion
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-anon-enum-enum-conversion- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables it by default.
- Code
-Wdeprecated-array-compare- Severity
- warning
- Message
comparison between two arrays is deprecated; to compare array addresses, use unary ‘+’ to decay operands to pointers
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-attributes- Severity
- warning
- Message
use of CUDA/HIP target attributes on deduction guides is deprecated; they will be rejected in a future version of Clang- Message
‘{}’ attribute is deprecated and may be removed in a future version of Clang- Message
‘lifetime_capture_by({})’ is deprecated; use ‘{}’ instead- Message
the ‘[[_Noreturn]]’ attribute spelling is deprecated in C23; use ‘[[noreturn]]’ instead- Message
applying attribute {} to a declaration is deprecated; apply it to the type instead- Message
specifying vector types with the ‘mode’ attribute is deprecated; use the ‘vector_size’ attribute instead
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdeprecated-builtins- Severity
- warning
- Message
builtin {} is deprecated; use {} instead- Message
builtin {} is deprecated
Clang enables it by default.
- Code
-Wdeprecated-comma-subscript- Severity
- warning
- Message
top-level comma expression in array subscript is deprecated in C++20 and unsupported in C++23
It also controls -Wdeprecated-copy-with-user-provided-copy. Clang has 5 messages for this flag.
- Code
-Wdeprecated-copy- Severity
- warning
- Message
definition of implicit copy- Message
constructor- Message
assignment operator- Message
assignment operator- Message
constructor
- Code
-Wdeprecated-copy-dtor- Severity
- warning
It also controls -Wdeprecated-copy-with-user-provided-dtor. Clang has 3 messages for this flag.
- Code
-Wdeprecated-copy-with-dtor- Severity
- warning
- Message
definition of implicit copy- Message
constructor- Message
assignment operator
Clang has 5 messages for this flag.
- Code
-Wdeprecated-copy-with-user-provided-copy- Severity
- warning
- Message
definition of implicit copy- Message
constructor- Message
assignment operator- Message
assignment operator- Message
constructor
Clang has 3 messages for this flag.
- Code
-Wdeprecated-copy-with-user-provided-dtor- Severity
- warning
- Message
definition of implicit copy- Message
constructor- Message
assignment operator
Clang enables it by default.
- Code
-Wdeprecated-coroutine- Severity
- warning
- Message
‘for co_await’ belongs to CoroutineTS instead of C++20, which is deprecated
Clang enables it by default. It also controls -Wdeprecated-declarations-switch-case. Clang has 7 messages for this flag.
- Code
-Wdeprecated-declarations- Severity
- warning
- Message
the {} attribute is deprecated; use ‘amdgpu_waves_per_eu’ instead- Message
specifying ‘uuid’ as an ATL attribute is deprecated; use __declspec instead- Message
use of C-style parameters in Objective-C method declarations is deprecated- Message
{} is deprecated- Message
{} may be deprecated because the receiver type is unknown- Message
{} is deprecated: {}- Message
property access is using {} method which is deprecated
… is deprecated. -Wdeprecated-declarations-switch-case
Clang enables it by default.
- Code
-Wdeprecated-declarations-switch-case- Severity
- warning
- Message
{} is deprecated
- Code
-Wdeprecated-dynamic-exception-spec- Severity
- warning
- Message
dynamic exception specifications are deprecated
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-enum-compare- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-enum-compare-conditional- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-enum-enum-conversion- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables it by default. Clang has 12 messages for this flag.
- Code
-Wdeprecated-enum-float-conversion- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
floating-point- Message
enumeration- Message
with
Clang has 5 messages for this flag.
- Code
-Wdeprecated-implementations- Severity
- warning
- Message
implementing deprecated- Message
method- Message
class- Message
category- Message
implementing unavailable method
Clang enables it by default.
- Code
-Wdeprecated-increment-bool- Severity
- warning
- Message
incrementing expression of type bool is deprecated and incompatible with C++17
Clang enables it by default.
- Code
-Wdeprecated-literal-operator- Severity
- warning
- Message
identifier {} preceded by whitespace in a literal operator declaration is deprecated
Clang enables it by default.
- Code
-Wdeprecated-missing-comma-variadic-parameter- Severity
- warning
- Message
declaration of a variadic function without a comma before ‘…’ is deprecated
Clang enables it by default. Clang has 4 messages for this flag.
- Code
-Wdeprecated-module-dot-map- Severity
- warning
- Message
‘{}’ as a module map name is deprecated, rename it to- Message
module.modulemap- Message
module.private.modulemap- Message
in the ‘Modules’ directory of the framework
A function. -Wdeprecated-non-prototype
Clang enables it by default. Clang has 12 messages for this flag.
- Code
-Wdeprecated-non-prototype- Severity
- warning
- Message
a function- Message
declaration- Message
definition- Message
and is not supported in C23- Message
and is treated as a zero-parameter prototype in C23, conflicting with a- Message
previous- Message
subsequent- Message
declaration
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdeprecated-objc-isa-usage- Severity
- warning
- Message
assignment to Objective-C’s isa is deprecated in favor of object_setClass()- Message
direct access to Objective-C’s isa is deprecated in favor of object_getClass()
Clang enables it by default. It also controls -Wdeprecated-objc-pointer-introspection-performSelector.
- Code
-Wdeprecated-objc-pointer-introspection- Severity
- warning
- Message
bitmasking for introspection of Objective-C object pointers is strongly discouraged
Clang enables it by default.
- Code
-Wdeprecated-objc-pointer-introspection-performSelector- Severity
- warning
- Message
bitmasking for introspection of Objective-C object pointers is strongly discouraged
Clang enables it by default.
- Code
-Wdeprecated-octal-literals- Severity
- warning
- Message
octal literals without a ‘0o’ prefix are deprecated
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdeprecated-ofast- Severity
- warning
- Message
argument ‘-Ofast’ is deprecated; use ‘-O3’ to enable only conforming optimizations, or consult the documentation for the same behavior- Message
argument ‘-Ofast’ is deprecated; use ‘-O3 -ffast-math -fstack-arrays -fno-protect-parens’ for the same behavior, or ‘-O3 -fstack-arrays’ to enable only conforming optimizations
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdeprecated-pragma- Severity
- warning
- Message
macro {} has been marked as deprecated- Message
: {}
- Code
-Wdeprecated-redundant-constexpr-static-def- Severity
- warning
- Message
out-of-line definition of constexpr static data member is redundant in C++17 and is deprecated
Clang enables it by default.
- Code
-Wdeprecated-register- Severity
- warning
- Message
‘register’ storage class specifier is deprecated and incompatible with C++17
Clang enables it by default.
- Code
-Wdeprecated-this-capture- Severity
- warning
- Message
implicit capture of ‘this’ with a capture default of ‘=’ is deprecated
Clang enables it by default.
- Code
-Wdeprecated-type- Severity
- warning
- Message
‘_ExtInt’ is deprecated; use ‘_BitInt’ instead
Decrement. -Wdeprecated-volatile
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wdeprecated-volatile- Severity
- warning
- Message
decrement- Message
increment- Message
use of result of assignment to object of volatile-qualified type {} is deprecated- Message
volatile-qualified parameter type {} is deprecated- Message
volatile-qualified return type {} is deprecated- Message
volatile qualifier in structured binding declaration is deprecated
- Code
-Wdeprecated-writable-strings- Severity
- warning
- Code
-Wdirect-ivar-access- Severity
- warning
- Message
instance variable {} is being directly accessed
- Code
-Wdisabled-macro-expansion- Severity
- warning
- Message
disabled expansion of recursive macro
- Code
-Wdisabled-optimization- Severity
- warning
- Code
-Wdiscard-qual- Severity
- warning
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdistributed-object-modifiers- Severity
- warning
- Message
conflicting distributed object modifiers on parameter type in implementation of {}- Message
conflicting distributed object modifiers on return type in implementation of {}
- Code
-Wdiv-by-zero- Severity
- warning
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdivision-by-zero- Severity
- warning
- Message
remainder- Message
division
Clang enables it by default.
- Code
-Wdll-attribute-on-redeclaration- Severity
- warning
- Message
redeclaration of {} should not add {} attribute
Clang enables it by default. It also controls -Wdllexport-explicit-instantiation-decl.
- Code
-Wdllexport-explicit-instantiation- Severity
- warning
- Message
‘dllexport’ attribute ignored on explicit instantiation definition
Clang enables it by default.
- Code
-Wdllexport-explicit-instantiation-decl- Severity
- warning
- Message
explicit instantiation declaration should not be ‘dllexport’
Clang enables it by default.
- Code
-Wdllimport-static-field-def- Severity
- warning
- Message
definition of dllimport static field
‘. -Wdocumentation
It also controls -Wdocumentation-deprecated-sync, -Wdocumentation-html. Clang has 80 messages for this flag.
- Code
-Wdocumentation- Severity
- warning
- Message
‘- Message
\- Message
@- Message
class- Message
interface- Message
protocol- Message
struct- Message
union
Clang has 3 messages for this flag.
- Code
-Wdocumentation-deprecated-sync- Severity
- warning
- Message
declaration is marked with ‘- Message
\- Message
@
Clang has 4 messages for this flag.
- Code
-Wdocumentation-html- Severity
- warning
- Message
HTML end tag ‘{}’ is forbidden- Message
HTML end tag does not match any start tag- Message
HTML tag ‘{}’ requires an end tag- Message
HTML start tag ‘{}’ closed by ‘{}’
It also controls -Wdocumentation-unknown-command.
- Code
-Wdocumentation-pedantic- Severity
- warning
- Message
whitespace is not allowed in parameter passing direction
Clang has 2 messages for this flag.
- Code
-Wdocumentation-unknown-command- Severity
- warning
- Message
unknown command tag name ‘{}’; did you mean ‘{}’?- Message
unknown command tag name
- Code
-Wdollar-in-identifier-extension- Severity
- warning
- Message
‘$’ in identifier
- Code
-Wdouble-promotion- Severity
- warning
- Message
implicit conversion increases floating-point precision: {} to {}
Clang enables some of the diagnostics that it controls by default. Clang has 3 messages for this flag.
- Code
-Wdtor-name- Severity
- warning
- Message
ISO C++ considers this destructor name lookup to be ambiguous- Message
ISO C++ requires the name after ‘::~’ to be found in the same scope as the name before ‘::~’- Message
qualified destructor name only found in lexical scope; omit the qualifier to find this type name by unqualified lookup
Clang has 3 messages for this flag.
- Code
-Wdtor-typedef- Severity
- error
- Message
destructor cannot be declared using a- Message
typedef- Message
type alias
Clang enables some of the diagnostics that it controls by default. Clang has 5 messages for this flag.
- Code
-Wduplicate-decl-specifier- Severity
- warning
- Message
duplicate ‘{}’ declaration specifier- Message
duplicate ‘{}’ declaration specifier- Message
multiple identical address spaces specified for type- Message
duplicate ‘{}’ declaration specifier- Message
duplicate interpolation modifier {}
- Code
-Wduplicate-enum- Severity
- warning
- Message
element {} has been implicitly assigned {} which another element has been assigned
Clang enables it by default.
- Code
-Wduplicate-interrupt-type- Severity
- warning
- Message
RISC-V ‘interrupt’ attribute type ‘{}’ specified more than once
- Code
-Wduplicate-method-arg- Severity
- warning
- Message
redeclaration of method parameter {}
- Code
-Wduplicate-method-match- Severity
- warning
- Message
multiple declarations of method {} found and ignored
Clang enables it by default.
- Code
-Wduplicate-protocol- Severity
- warning
- Message
duplicate protocol definition of {} is ignored
Clang enables it by default.
- Code
-Wdxil-validation- Severity
- warning
- Message
dxv not found; resulting DXIL will not be validated or signed for use in release environment
Clang enables it by default. Clang has 9 messages for this flag.
- Code
-Wdynamic-class-memaccess- Severity
- warning
- Message
destination for- Message
source of- Message
first operand of- Message
second operand of- Message
class containing a- Message
overwritten- Message
copied- Message
moved
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wdynamic-debugging- Severity
- warning
- Message
‘-fdynamic-debugging’ ignored: requires debug info- Message
ignoring -fdynamic-debugging: unable to create target: ‘{}’
Clang enables some of the diagnostics that it controls by default. It also controls -Wdeprecated-dynamic-exception-spec.
- Code
-Wdynamic-exception-spec- Severity
- error
- Message
ISO C++17 does not allow dynamic exception specifications
Clang enables it by default.
- Code
-Weager-load-cxx-named-modules- Severity
- warning
- Message
the form ‘-fmodule-file=<BMI-path>’ is deprecated for standard C++ named modules; consider to use ‘-fmodule-file=<module-name>=<BMI-path>’ instead
- Code
-Weffc++- Severity
- warning
Clang has 2 messages for this flag.
- Code
-Welaborated-enum-base- Severity
- error
- Message
non-defining declaration of enumeration with a fixed underlying type is only permitted as a standalone declaration- Message
; missing list of enumerators?
Clang has 3 messages for this flag.
- Code
-Welaborated-enum-class- Severity
- error
- Message
reference to enumeration must use ‘enum’ not ‘enum- Message
struct- Message
class
- Code
-Wembedded-directive- Severity
- warning
- Message
embedding a directive within macro arguments has undefined behavior
Clang enables it by default. Clang has 6 messages for this flag.
- Code
-Wempty-body- Severity
- warning
- Message
defer statement has empty body- Message
for loop has empty body- Message
if statement has empty body- Message
range-based for loop has empty body- Message
switch statement has empty body- Message
while loop has empty body
Clang enables it by default.
- Code
-Wempty-decomposition- Severity
- warning
- Message
ISO C++17 does not allow a structured binding group to be empty
Clang has 4 messages for this flag.
- Code
-Wempty-init-stmt- Severity
- warning
- Message
empty initialization statement of ‘- Message
if- Message
switch- Message
range-based for
- Code
-Wempty-translation-unit- Severity
- warning
- Message
ISO C requires a translation unit to contain at least one declaration
Clang enables it by default.
- Code
-Wencode-type- Severity
- warning
- Message
encoding of {} type is incomplete because {} component has unknown encoding
- Code
-Wendif-labels- Severity
- warning
Clang enables it by default. It also controls -Wdeprecated-enum-compare, -Wenum-compare-switch. Clang has 6 messages for this flag.
- Code
-Wenum-compare- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables some of the diagnostics that it controls by default. It also controls -Wdeprecated-enum-compare-conditional. Clang has 6 messages for this flag.
- Code
-Wenum-compare-conditional- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wenum-compare-switch- Severity
- warning
- Message
comparison of different enumeration types in switch statement- Message
({} and {})
Clang enables it by default.
- Code
-Wenum-compare-typo- Severity
- warning
- Message
comparison operator ‘{}’ is potentially a typo for a shift operator ‘{}’
Clang enables some of the diagnostics that it controls by default. It also controls -Wenum-compare-conditional, -Wenum-enum-conversion, -Wenum-float-conversion, -Wimplicit-enum-enum-cast.
- Code
-Wenum-conversion- Severity
- warning
Clang enables some of the diagnostics that it controls by default. It also controls -Wdeprecated-enum-enum-conversion. Clang has 13 messages for this flag.
- Code
-Wenum-enum-conversion- Severity
- error
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
({} and {})- Message
invalid- Message
arithmetic between
Clang enables some of the diagnostics that it controls by default. It also controls -Wdeprecated-enum-float-conversion. Clang has 12 messages for this flag.
- Code
-Wenum-float-conversion- Severity
- warning
- Message
arithmetic between- Message
bitwise operation between- Message
comparison of- Message
conditional expression between- Message
compound assignment of- Message
floating-point- Message
enumeration- Message
with
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wenum-too-large- Severity
- warning
- Message
enumeration values exceed range of largest integer- Message
incremented enumerator value {} is not representable in the largest integer type
Clang enables it by default. Clang has 5 messages for this flag.
- Code
-Wexceptions- Severity
- warning
- Message
cannot refer to a non-static member from the handler of a- Message
constructor- Message
destructor- Message
exception of type {} will be caught by earlier handler- Message
{} has a non-throwing exception specification but can still throw
Clang enables it by default. Clang has 10 messages for this flag.
- Code
-Wexcess-initializers- Severity
- warning
- Message
excess elements in- Message
array- Message
vector- Message
matrix- Message
scalar- Message
union- Message
struct- Message
excess elements in initializer for indivisible sizeless type {}
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wexcessive-regsave- Severity
- warning
- Message
interrupt service routine- Message
function with attribute ‘no_caller_saved_registers’
- Code
-Wexit-time-destructors- Severity
- warning
- Message
declaration requires an exit-time destructor
Clang has 2 messages for this flag.
- Code
-Wexpansion-stmt-missing-braces- Severity
- warning
- Message
ISO C++ forbids attributes before the compound statement of an expansion statement- Message
ISO C++ requires the body of an expansion statement to be a compound statement
Clang enables some of the diagnostics that it controls by default. Clang has 2 messages for this flag.
- Code
-Wexpansion-to-defined- Severity
- warning
- Message
macro expansion producing ‘defined’ has undefined behavior- Message
macro expansion producing ‘defined’ has undefined behavior
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wexperimental-option- Severity
- warning
- Message
OpenMP support for version {} in flang is still incomplete- Message
the specification for OpenMP version {} is still under development; the syntax and semantics of new features may be subject to change
Clang enables it by default. Clang has 2 messages for this flag.
- Code
-Wexplicit-initialize-call- Severity
- warning
- Message
explicit call to +initialize results in duplicate call to +initialize- Message
explicit call to [super initialize] should only be in implementation of +initialize
- Code
-Wexplicit-ownership-type- Severity
- warning
- Message
method parameter of type {} with no explicit ownership
Clang enables it by default.
- Code
-Wexplicit-specialization-storage-class- Severity
- warning
- Message
explicit specialization cannot have a storage class
- Code
-Wexport-unnamed- Severity
- warning
Clang enables it by default.
- Code
-Wext-cxx-type-aware-allocators- Severity
- warning
- Message
type aware allocators are a Clang extension
Empty. -Wextern-c-compat
Clang enables it by default. Clang has 5 messages for this flag.
- Code
-Wextern-c-compat- Severity
- warning
- Message
empty- Message
struct- Message
union- Message
size 1- Message
non-zero size
Clang enables it by default.
- Code
-Wextern-initializer- Severity
- warning
- Message
‘extern’ variable has an initializer
Clang enables it by default. Clang has 3 messages for this flag.
- Code
-Wfinal-dtor-non-final-class- Severity
- warning
- Message
class with destructor marked ‘- Message
final- Message
sealed
Clang enables it by default. Clang has 3 messages for this flag.
- Code
-Wfinal-macro- Severity
- warning
- Message
macro {} has been marked as final and should not be- Message
undefined- Message
redefined
Clang enables it by default.
- Code
-Wfixed-point-overflow- Severity
- warning
- Message
overflow in expression; result is {} with type {}
Clang enables it by default.
- Code
-Wflag-enum- Severity
- warning
- Message
enumeration value {} is out of range of flags in enumeration type {}
Clang has 2 messages for this flag.
- Code
-Wflexible-array-extensions- Severity
- warning
- Message
{} may not be used as an array element due to flexible array member- Message
{} may not be nested in a struct due to flexible array member
It also controls -Wfloat-overflow-conversion, -Wfloat-zero-conversion.
- Code
-Wfloat-conversion- Severity
- warning
- Message
implicit conversion turns floating-point number into integer: {} to {}
- Code
-Wfloat-equal- Severity
- warning
- Message
comparing floating point with == or != is unsafe
Clang has 2 messages for this flag.
- Code
-Wfloat-overflow-conversion- Severity
- warning
- Message
implicit conversion from {} to {} changes value from {} to {}- Message
implicit conversion of out of range value from {} to {} is undefined
- Code
-Wfloat-zero-conversion- Severity
- warning
- Message
implicit conversion from {} to {} changes non-zero value from {} to {}
Clang has 9 messages for this flag.
- Code
-Wfor-loop-analysis- Severity
- warning
- Message
variable {} is- Message
decremented- Message
incremented- Message
variable- Message
s- Message
{}- Message
s {} and {}- Message
s {}, {}, and {}
Clang enables it by default. It also controls -Wformat-extra-args, -Wformat-insufficient-args, -Wformat-invalid-specifier, -Wformat-overflow, -Wformat-security, -Wformat-truncation, -Wformat-y2k, -Wformat-zero-length, -Wnonnull. Clang has 61 messages for this flag.
- Code
-Wformat- Severity
- warning
- Message
using ‘%P’ format specifier without precision- Message
using ‘%P’ format specifier with an Objective-C pointer results in dumping runtime object structure, not object value- Message
values of type- Message
enum values with underlying type- Message
using ‘{}’ format specifier, but argument has boolean value- Message
format argument modifies specifier at position {}, but it should modify specifier at position {}- Message
format argument is- Message
a value
Fewer. -Wformat-insufficient-args
Clang enables it by default. Clang has 3 messages for this flag.
- Code
-Wformat-insufficient-args- Severity
- warning
- Message
fewer- Message
more- Message
more ‘%’ conversions than data arguments
Clang enables it by default.
- Code
-Wformat-invalid-specifier- Severity
- warning
- Message
invalid conversion specifier ‘{}’
‘…’. -Wformat-non-iso
Clang has 5 messages for this flag.
- Code
-Wformat-non-iso- Severity
- warning
- Message
‘{}’- Message
length modifier- Message
conversion specifier- Message
using length modifier ‘{}’ with conversion specifier ‘{}’ is not supported by ISO C- Message
positional arguments are not supported by ISO C
It also controls -Wmissing-format-attribute.
- Code
-Wformat-nonliteral- Severity
- warning
- Message
format string is not a string literal
Clang enables it by default. It also controls -Wformat-overflow-non-kprintf.
- Code
-Wformat-overflow- Severity
- warning
- Message
‘{}’ will always overflow; destination buffer has size {}, but format string expands to at least {}
Clang enables it by default.
- Code
-Wformat-overflow-non-kprintf- Severity
- warning
- Message
‘{}’ will always overflow; destination buffer has size {}, but format string expands to at least {}
Clang has 6 messages for this flag.
- Code
-Wformat-pedantic- Severity
- warning
- Message
values of type- Message
enum values with underlying type- Message
signedness of format specifier ‘{}’ is incompatible with ‘{}’- Message
format specifies type {} but the argument has- Message
type- Message
underlying type
Clang enables it by default.
- Code
-Wformat-security- Severity
- warning
- Message
format string is not a string literal (potentially insecure)
Clang has 4 messages for this flag.
- Code
-Wformat-signedness- Severity
- warning
- Message
signedness of format specifier ‘{}’ is incompatible with ‘{}’- Message
format specifies type {} but the argument has- Message
type- Message
underlying type
Clang enables it by default. It also controls -Wformat-truncation-non-kprintf.
- Code
-Wformat-truncation- Severity
- warning
- Message
‘{}’ will always be truncated; specified size is {}, but format string expands to at least {}
Clang enables it by default.
- Code
-Wformat-truncation-non-kprintf- Severity
- warning
- Message
‘{}’ will always be truncated; specified size is {}, but format string expands to at least {}
Clang has 3 messages for this flag.
- Code
-Wformat-type-confusion- Severity
- warning
- Message
format specifies type {} but the argument has- Message
type- Message
underlying type
- Code
-Wformat-y2k- Severity
- warning
Clang enables it by default.
- Code
-Wformat-zero-length- Severity
- warning
- Message
format string is empty
Clang enables some of the diagnostics that it controls by default. It also controls -Wformat-nonliteral, -Wformat-security, -Wformat-y2k.
- Code
-Wformat=2- Severity
- warning
Clang enables it by default. It also controls -Wformat-overflow, -Wformat-truncation. Clang has 7 messages for this flag.
- Code
-Wfortify-source- Severity
- warning
- Message
‘{}’ may overflow; destination buffer in argument {} has size {}, but the corresponding specifier may require size {}- Message
‘{}’ size argument is negative- Message
‘{}’ will always overflow; destination buffer has size {}, but size argument is {}- Message
‘{}’ will always read past the end of the source buffer; source buffer has size {}, but the size is {}- Message
‘{}’ size argument is too large; destination buffer has size {}, but size argument is {}- Message
‘{}’ will always overflow; destination buffer has size {}, but the source string has length {} (including NUL byte)- Message
‘umask’ argument sets non-file-permission bits (0{}); those bits are ignored
- Code
-Wfour-char-constants- Severity
- warning
- Message
multi-character character constant
- Code
-Wframe-address- Severity
- warning
- Message
calling ‘{}’ with a nonzero argument is unsafe
Clang enables it by default.
- Code
-Wframe-larger-than- Severity
- warning
- Message
stack frame size ({}) exceeds limit ({}) in ‘{}’
Clang enables it by default.
- Code
-Wframework-include-private-from-public- Severity
- warning
- Message
public framework header includes private framework header ‘{}’
Clang enables it by default. Clang has 4 messages for this flag.
- Code
-Wfree-nonheap-object- Severity
- warning
- Message
attempt to call {} on non-heap- Message
object {}- Message
object: block expression- Message
object: lambda-to-function-pointer conversion
Clang enables it by default.
- Code
-Wfriend-enum- Severity
- warning
- Message
elaborated enum specifier cannot be declared as a friend
Clang enables it by default.
- Code
-Wfunction-def-in-objc-container- Severity
- warning
- Message
function definition inside an Objective-C container is deprecated