blob: a4c10ccd0e405f08e8dedf13c72240e616663a92 [file] [log] [blame]
Richard Smithb6a3b4b2016-09-12 05:58:29 +00001..
2 -------------------------------------------------------------------
3 NOTE: This file is automatically generated by running clang-tblgen
4 -gen-diag-docs. Do not edit this file by hand!!
5 -------------------------------------------------------------------
6
7.. Add custom CSS to output. FIXME: This should be put into <head> rather
8 than the start of <body>.
9.. raw:: html
10
11 <style>
12 table.docutils {
13 width: 1px;
14 }
15 table.docutils td {
16 border: none;
17 padding: 0;
18 vertical-align: middle;
19 white-space: nowrap;
20 width: 1px;
21 }
22 table.docutils tr + tr {
23 border-top: 0.2em solid #aaa;
24 }
25 .error {
26 font-family: monospace;
27 font-weight: bold;
Richard Smithac205312016-09-12 17:55:49 +000028 color: #c00;
Richard Smithb6a3b4b2016-09-12 05:58:29 +000029 }
30 .warning {
31 font-family: monospace;
32 font-weight: bold;
Richard Smith9d5f86b2016-09-14 00:35:56 +000033 color: #80a;
Richard Smithb6a3b4b2016-09-12 05:58:29 +000034 }
35 .remark {
36 font-family: monospace;
37 font-weight: bold;
38 color: #00c;
39 }
40 .diagtext {
41 font-family: monospace;
42 font-weight: bold;
43 }
44 </style>
45
46.. FIXME: Format this as .diagtext. rST appears to not support this. :(
47.. |nbsp| unicode:: 0xA0
48 :trim:
49
50.. Roles generated by clang-tblgen.
51.. role:: error
52.. role:: warning
53.. role:: remark
54.. role:: diagtext
55.. role:: placeholder(emphasis)
56
57=========================
58Diagnostic flags in Clang
59=========================
60.. contents::
61 :local:
62
63Introduction
64============
65
66This page lists the diagnostic flags currently supported by Clang.
67
68Diagnostic flags
69================
70
71-W
72--
73Synonym for `-Wextra`_.
74
75
76-W#pragma-messages
77------------------
78This diagnostic is enabled by default.
79
80**Diagnostic text:**
81
82The text of this diagnostic is not controlled by Clang.
83
84
85-W#warnings
86-----------
87This diagnostic is enabled by default.
88
89**Diagnostic text:**
90
91The text of this diagnostic is not controlled by Clang.
92
93
94-WCFString-literal
95------------------
96This diagnostic is enabled by default.
97
98**Diagnostic text:**
99
100+------------------------------------------------------------------------------------------------------------------------------------+
101|:warning:`warning:` |nbsp| :diagtext:`input conversion stopped due to an input byte that does not belong to the input codeset UTF-8`|
102+------------------------------------------------------------------------------------------------------------------------------------+
103
104
105-WCL4
106-----
107Some of the diagnostics controlled by this flag are enabled by default.
108
109Controls `-Wall`_, `-Wextra`_.
110
111
112-WIndependentClass-attribute
113----------------------------
114This diagnostic is enabled by default.
115
116**Diagnostic text:**
117
118+------------------------------------------------------------------------------------------------------------------------------+
119|:warning:`warning:` |nbsp| :diagtext:`'objc\_independent\_class' attribute may be put on a typedef only; attribute is ignored`|
120+------------------------------------------------------------------------------------------------------------------------------+
121
122+----------------------------------------------------------------------------------------------------------------------------------------------------+
123|:warning:`warning:` |nbsp| :diagtext:`'objc\_independent\_class' attribute may be put on Objective-C object pointer type only; attribute is ignored`|
124+----------------------------------------------------------------------------------------------------------------------------------------------------+
125
126
127-WNSObject-attribute
128--------------------
129This diagnostic is enabled by default.
130
131**Diagnostic text:**
132
133+--------------------------------------------------------------------------------------------------------------+
134|:warning:`warning:` |nbsp| :diagtext:`'NSObject' attribute may be put on a typedef only; attribute is ignored`|
135+--------------------------------------------------------------------------------------------------------------+
136
137
138-Wabi
139-----
140This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
141
142-Wabsolute-value
143----------------
144This diagnostic is enabled by default.
145
146**Diagnostic text:**
147
148+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
149|:warning:`warning:` |nbsp| :diagtext:`absolute value function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`given an argument of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`but has parameter of type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`which may cause truncation of value`|
150+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
151
152+---------------------------------------------------------------------------+----------------------+---------------------------------------------------------------------------------+
153|:warning:`warning:` |nbsp| :diagtext:`taking the absolute value of` |nbsp| |+--------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is suspicious`|
154| ||:diagtext:`pointer` || |
155| |+--------------------+| |
156| ||:diagtext:`function`|| |
157| |+--------------------+| |
158| ||:diagtext:`array` || |
159| |+--------------------+| |
160+---------------------------------------------------------------------------+----------------------+---------------------------------------------------------------------------------+
161
162+------------------------------------------------------------------------------------------------------------------------------------------+
163|:warning:`warning:` |nbsp| :diagtext:`taking the absolute value of unsigned type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has no effect`|
164+------------------------------------------------------------------------------------------------------------------------------------------+
165
166+----------------------------------------------------+----------------------------+------------------------------------------------------------------------------------------------------------------+----------------------------+------------------------+
167|:warning:`warning:` |nbsp| :diagtext:`using` |nbsp| |+--------------------------+| |nbsp| :diagtext:`absolute value function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`when argument is of` |nbsp| |+--------------------------+| |nbsp| :diagtext:`type`|
168| ||:diagtext:`integer` || ||:diagtext:`integer` || |
169| |+--------------------------+| |+--------------------------+| |
170| ||:diagtext:`floating point`|| ||:diagtext:`floating point`|| |
171| |+--------------------------+| |+--------------------------+| |
172| ||:diagtext:`complex` || ||:diagtext:`complex` || |
173| |+--------------------------+| |+--------------------------+| |
174+----------------------------------------------------+----------------------------+------------------------------------------------------------------------------------------------------------------+----------------------------+------------------------+
175
176
177-Wabstract-final-class
178----------------------
179This diagnostic is enabled by default.
180
181**Diagnostic text:**
182
183+-----------------------------------------------------------------+--------------------+-------------+
184|:warning:`warning:` |nbsp| :diagtext:`abstract class is marked '`|+------------------+|:diagtext:`'`|
185| ||:diagtext:`final` || |
186| |+------------------+| |
187| ||:diagtext:`sealed`|| |
188| |+------------------+| |
189+-----------------------------------------------------------------+--------------------+-------------+
190
191
192-Wabstract-vbase-init
193---------------------
194**Diagnostic text:**
195
196+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
197|:warning:`warning:` |nbsp| :diagtext:`initializer for virtual base class` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of abstract class` |nbsp| :placeholder:`B` |nbsp| :diagtext:`will never be used`|
198+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
199
200
201-Waddress
202---------
203This diagnostic is enabled by default.
204
205Controls `-Wpointer-bool-conversion`_, `-Wstring-compare`_, `-Wtautological-pointer-compare`_.
206
207
208-Waddress-of-array-temporary
209----------------------------
210This diagnostic is enabled by default.
211
212**Diagnostic text:**
213
214+---------------------------------------------------------------------------------------------------------------------------------------------+
215|:warning:`warning:` |nbsp| :diagtext:`pointer is initialized by a temporary array, which will be destroyed at the end of the full-expression`|
216+---------------------------------------------------------------------------------------------------------------------------------------------+
217
218
219-Waddress-of-packed-member
220--------------------------
221This diagnostic is enabled by default.
222
223**Diagnostic text:**
224
225+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
226|:warning:`warning:` |nbsp| :diagtext:`taking address of packed member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of class or structure` |nbsp| :placeholder:`B` |nbsp| :diagtext:`may result in an unaligned pointer value`|
227+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
228
229
230-Waddress-of-temporary
231----------------------
232This diagnostic is an error by default, but the flag ``-Wno-address-of-temporary`` can be used to disable the error.
233
234**Diagnostic text:**
235
236+-----------------------------------------------------------------------------------------------------------+
237|:error:`error:` |nbsp| :diagtext:`taking the address of a temporary object of type` |nbsp| :placeholder:`A`|
238+-----------------------------------------------------------------------------------------------------------+
239
240
241-Waggregate-return
242------------------
243This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
244
245-Wall
246-----
247Some of the diagnostics controlled by this flag are enabled by default.
248
249Controls `-Wmost`_, `-Wparentheses`_, `-Wswitch`_, `-Wswitch-bool`_.
250
251
252-Wambiguous-ellipsis
253--------------------
254This diagnostic is enabled by default.
255
256**Diagnostic text:**
257
258+------------------------------------------------------------------------------------------------+---------------------------------------------+
259|:warning:`warning:` |nbsp| :diagtext:`'...' in this location creates a C-style varargs function`|+-------------------------------------------+|
260| ||:diagtext:`, not a function parameter pack`||
261| |+-------------------------------------------+|
262| || ||
263| |+-------------------------------------------+|
264+------------------------------------------------------------------------------------------------+---------------------------------------------+
265
266
267-Wambiguous-macro
268-----------------
269This diagnostic is enabled by default.
270
271**Diagnostic text:**
272
273+-------------------------------------------------------------------------------------------+
274|:warning:`warning:` |nbsp| :diagtext:`ambiguous expansion of macro` |nbsp| :placeholder:`A`|
275+-------------------------------------------------------------------------------------------+
276
277
278-Wambiguous-member-template
279---------------------------
280This diagnostic is enabled by default.
281
282**Diagnostic text:**
283
284+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
285|:warning:`warning:` |nbsp| :diagtext:`lookup of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in member access expression is ambiguous; using member of` |nbsp| :placeholder:`B`|
286+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
287
288
289-Wanalyzer-incompatible-plugin
290------------------------------
291This diagnostic is enabled by default.
292
293**Diagnostic text:**
294
295+----------------------------------------------------------------------------------------------------------------------------------------+
296|:warning:`warning:` |nbsp| :diagtext:`checker plugin '`:placeholder:`A`:diagtext:`' is not compatible with this version of the analyzer`|
297+----------------------------------------------------------------------------------------------------------------------------------------+
298
299
300-Wanonymous-pack-parens
301-----------------------
302This diagnostic is enabled by default.
303
304**Diagnostic text:**
305
306+---------------------------------------------------------------------------------------------------------+
307|:warning:`warning:` |nbsp| :diagtext:`ISO C++11 requires a parenthesized pack declaration to have a name`|
308+---------------------------------------------------------------------------------------------------------+
309
310
311-Warc
312-----
313This diagnostic is enabled by default.
314
315Controls `-Warc-unsafe-retained-assign`_, `-Warc-retain-cycles`_, `-Warc-non-pod-memaccess`_.
316
317
318-Warc-bridge-casts-disallowed-in-nonarc
319---------------------------------------
320This diagnostic is enabled by default.
321
322**Diagnostic text:**
323
324+-------------------------------------------------------------------------------------------------------------+
325|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' casts have no effect when not using ARC`|
326+-------------------------------------------------------------------------------------------------------------+
327
328
329-Warc-maybe-repeated-use-of-weak
330--------------------------------
331**Diagnostic text:**
332
333+---------------------------------------------------+-------------------------------+------------------------------------------------------------------------------------------+----------------------+-------------------------------------------------------------------------------------------------------------+
334|:warning:`warning:` |nbsp| :diagtext:`weak` |nbsp| |+-----------------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`may be accessed multiple times in this` |nbsp| |+--------------------+| |nbsp| :diagtext:`and may be unpredictably set to nil; assign to a strong variable to keep the object alive`|
335| ||:diagtext:`variable` || ||:diagtext:`function`|| |
336| |+-----------------------------+| |+--------------------+| |
337| ||:diagtext:`property` || ||:diagtext:`method` || |
338| |+-----------------------------+| |+--------------------+| |
339| ||:diagtext:`implicit property`|| ||:diagtext:`block` || |
340| |+-----------------------------+| |+--------------------+| |
341| ||:diagtext:`instance variable`|| ||:diagtext:`lambda` || |
342| |+-----------------------------+| |+--------------------+| |
343+---------------------------------------------------+-------------------------------+------------------------------------------------------------------------------------------+----------------------+-------------------------------------------------------------------------------------------------------------+
344
345
346-Warc-non-pod-memaccess
347-----------------------
348This diagnostic is enabled by default.
349
350**Diagnostic text:**
351
352+---------------------------+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
353|:warning:`warning:` |nbsp| |+---------------------------+| |nbsp| :diagtext:`this` |nbsp| :placeholder:`B` |nbsp| :diagtext:`call is a pointer to ownership-qualified type` |nbsp| :placeholder:`C`|
354| ||:diagtext:`destination for`|| |
355| |+---------------------------+| |
356| ||:diagtext:`source of` || |
357| |+---------------------------+| |
358+---------------------------+-----------------------------+-----------------------------------------------------------------------------------------------------------------------------------------+
359
360
361-Warc-performSelector-leaks
362---------------------------
363This diagnostic is enabled by default.
364
365**Diagnostic text:**
366
367+-------------------------------------------------------------------------------------------------------+
368|:warning:`warning:` |nbsp| :diagtext:`performSelector may cause a leak because its selector is unknown`|
369+-------------------------------------------------------------------------------------------------------+
370
371
372-Warc-repeated-use-of-weak
373--------------------------
374Also controls `-Warc-maybe-repeated-use-of-weak`_.
375
376**Diagnostic text:**
377
378+---------------------------------------------------+-------------------------------+--------------------------------------------------------------------------------------+----------------------+-------------------------------------------------------------------------------------------------------------+
379|:warning:`warning:` |nbsp| :diagtext:`weak` |nbsp| |+-----------------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`is accessed multiple times in this` |nbsp| |+--------------------+| |nbsp| :diagtext:`but may be unpredictably set to nil; assign to a strong variable to keep the object alive`|
380| ||:diagtext:`variable` || ||:diagtext:`function`|| |
381| |+-----------------------------+| |+--------------------+| |
382| ||:diagtext:`property` || ||:diagtext:`method` || |
383| |+-----------------------------+| |+--------------------+| |
384| ||:diagtext:`implicit property`|| ||:diagtext:`block` || |
385| |+-----------------------------+| |+--------------------+| |
386| ||:diagtext:`instance variable`|| ||:diagtext:`lambda` || |
387| |+-----------------------------+| |+--------------------+| |
388+---------------------------------------------------+-------------------------------+--------------------------------------------------------------------------------------+----------------------+-------------------------------------------------------------------------------------------------------------+
389
390
391-Warc-retain-cycles
392-------------------
393This diagnostic is enabled by default.
394
395**Diagnostic text:**
396
397+------------------------------------------------------------------------------------------------------------------------------------------------------+
398|:warning:`warning:` |nbsp| :diagtext:`capturing` |nbsp| :placeholder:`A` |nbsp| :diagtext:`strongly in this block is likely to lead to a retain cycle`|
399+------------------------------------------------------------------------------------------------------------------------------------------------------+
400
401
402-Warc-unsafe-retained-assign
403----------------------------
404This diagnostic is enabled by default.
405
406**Diagnostic text:**
407
408+--------------------------------------------------------+---------------------------------+-------------------------------------+----------------------+------------------------------------------------------+
409|:warning:`warning:` |nbsp| :diagtext:`assigning` |nbsp| |+-------------------------------+| |nbsp| :diagtext:`to a weak` |nbsp| |+--------------------+|:diagtext:`; object will be released after assignment`|
410| ||:diagtext:`array literal` || ||:diagtext:`property`|| |
411| |+-------------------------------+| |+--------------------+| |
412| ||:diagtext:`dictionary literal` || ||:diagtext:`variable`|| |
413| |+-------------------------------+| |+--------------------+| |
414| ||:diagtext:`numeric literal` || | | |
415| |+-------------------------------+| | | |
416| ||:diagtext:`boxed expression` || | | |
417| |+-------------------------------+| | | |
418| ||:diagtext:`<should not happen>`|| | | |
419| |+-------------------------------+| | | |
420| ||:diagtext:`block literal` || | | |
421| |+-------------------------------+| | | |
422+--------------------------------------------------------+---------------------------------+-------------------------------------+----------------------+------------------------------------------------------+
423
424+---------------------------------------------------------------------------+--------------------------------+--------+----------------------+------------------------------------------------------+
425|:warning:`warning:` |nbsp| :diagtext:`assigning retained object to` |nbsp| |+------------------------------+| |nbsp| |+--------------------+|:diagtext:`; object will be released after assignment`|
426| ||:diagtext:`weak` || ||:diagtext:`property`|| |
427| |+------------------------------+| |+--------------------+| |
428| ||:diagtext:`unsafe\_unretained`|| ||:diagtext:`variable`|| |
429| |+------------------------------+| |+--------------------+| |
430+---------------------------------------------------------------------------+--------------------------------+--------+----------------------+------------------------------------------------------+
431
432+-----------------------------------------------------------------------------------------------------------------------------+
433|:warning:`warning:` |nbsp| :diagtext:`assigning retained object to unsafe property; object will be released after assignment`|
434+-----------------------------------------------------------------------------------------------------------------------------+
435
436
437-Warray-bounds
438--------------
439This diagnostic is enabled by default.
440
441**Diagnostic text:**
442
443+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+-------------+
444|:warning:`warning:` |nbsp| :diagtext:`array index` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is past the end of the array (which contains` |nbsp| :placeholder:`B` |nbsp| :diagtext:`element`|+-------------+|:diagtext:`)`|
445| || || |
446| |+-------------+| |
447| ||:diagtext:`s`|| |
448| |+-------------+| |
449+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+-------------+
450
451+----------------------------------------------------------------------------------------------------------------------------------+
452|:warning:`warning:` |nbsp| :diagtext:`array index` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is before the beginning of the array`|
453+----------------------------------------------------------------------------------------------------------------------------------+
454
455+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
456|:warning:`warning:` |nbsp| :diagtext:`array argument is too small; contains` |nbsp| :placeholder:`A` |nbsp| :diagtext:`elements, callee requires at least` |nbsp| :placeholder:`B`|
457+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
458
459+-----------------------------------------------------------------------------------+
460|:warning:`warning:` |nbsp| :diagtext:`'static' has no effect on zero-length arrays`|
461+-----------------------------------------------------------------------------------+
462
463
464-Warray-bounds-pointer-arithmetic
465---------------------------------
466**Diagnostic text:**
467
468+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+-------------+
469|:warning:`warning:` |nbsp| :diagtext:`the pointer incremented by` |nbsp| :placeholder:`A` |nbsp| :diagtext:`refers past the end of the array (that contains` |nbsp| :placeholder:`B` |nbsp| :diagtext:`element`|+-------------+|:diagtext:`)`|
470| || || |
471| |+-------------+| |
472| ||:diagtext:`s`|| |
473| |+-------------+| |
474+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+-------------+
475
476+-----------------------------------------------------------------------------------------------------------------------------------------------------+
477|:warning:`warning:` |nbsp| :diagtext:`the pointer decremented by` |nbsp| :placeholder:`A` |nbsp| :diagtext:`refers before the beginning of the array`|
478+-----------------------------------------------------------------------------------------------------------------------------------------------------+
479
480
481-Wasm
482-----
483Synonym for `-Wasm-operand-widths`_.
484
485
486-Wasm-operand-widths
487--------------------
488This diagnostic is enabled by default.
489
490**Diagnostic text:**
491
492+-----------------------------------------------------------------------------------------------------------------------+
493|:warning:`warning:` |nbsp| :diagtext:`value size does not match register size specified by the constraint and modifier`|
494+-----------------------------------------------------------------------------------------------------------------------+
495
496
497-Wassign-enum
498-------------
499**Diagnostic text:**
500
501+---------------------------------------------------------------------------------------------------------------+
502|:warning:`warning:` |nbsp| :diagtext:`integer constant not in range of enumerated type` |nbsp| :placeholder:`A`|
503+---------------------------------------------------------------------------------------------------------------+
504
505
506-Wassume
507--------
508This diagnostic is enabled by default.
509
510**Diagnostic text:**
511
512+-----------------------------------------------------------------------------------------------------------------------------------------+
513|:warning:`warning:` |nbsp| :diagtext:`the argument to` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has side effects that will be discarded`|
514+-----------------------------------------------------------------------------------------------------------------------------------------+
515
516
517-Wat-protocol
518-------------
519This diagnostic is enabled by default.
520
521**Diagnostic text:**
522
523+-------------------------------------------------------------------------------------------------------------------+
524|:warning:`warning:` |nbsp| :diagtext:`@protocol is using a forward protocol declaration of` |nbsp| :placeholder:`A`|
525+-------------------------------------------------------------------------------------------------------------------+
526
527
528-Watomic-memory-ordering
529------------------------
530This diagnostic is enabled by default.
531
532**Diagnostic text:**
533
534+-------------------------------------------------------------------------------------------+
535|:warning:`warning:` |nbsp| :diagtext:`memory order argument to atomic operation is invalid`|
536+-------------------------------------------------------------------------------------------+
537
538
539-Watomic-properties
540-------------------
541Controls `-Wimplicit-atomic-properties`_, `-Wcustom-atomic-properties`_.
542
543
544-Watomic-property-with-user-defined-accessor
545--------------------------------------------
546This diagnostic is enabled by default.
547
548**Diagnostic text:**
549
550+--------------------------------------------------------------------------------------------------------------------------------------------+--------------------+-----------------------------------------------+--------------------+
551|:warning:`warning:` |nbsp| :diagtext:`writable atomic property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot pair a synthesized` |nbsp| |+------------------+| |nbsp| :diagtext:`with a user defined` |nbsp| |+------------------+|
552| ||:diagtext:`getter`|| ||:diagtext:`getter`||
553| |+------------------+| |+------------------+|
554| ||:diagtext:`setter`|| ||:diagtext:`setter`||
555| |+------------------+| |+------------------+|
556+--------------------------------------------------------------------------------------------------------------------------------------------+--------------------+-----------------------------------------------+--------------------+
557
558
559-Wattribute-packed-for-bitfield
560-------------------------------
561This diagnostic is enabled by default.
562
563**Diagnostic text:**
564
565+-------------------------------------------------------------------------------------------------------------------------------------------------+
566|:warning:`warning:` |nbsp| :diagtext:`'packed' attribute was ignored on bit-fields with single-byte alignment in older versions of GCC and Clang`|
567+-------------------------------------------------------------------------------------------------------------------------------------------------+
568
569
570-Wattributes
571------------
572This diagnostic is enabled by default.
573
574Controls `-Wunknown-attributes`_, `-Wignored-attributes`_.
575
576
577-Wauto-disable-vptr-sanitizer
578-----------------------------
579This diagnostic is enabled by default.
580
581**Diagnostic text:**
582
583+------------------------------------------------------------------------------------------------------+
584|:warning:`warning:` |nbsp| :diagtext:`implicitly disabling vptr sanitizer because rtti wasn't enabled`|
585+------------------------------------------------------------------------------------------------------+
586
587
588-Wauto-import
589-------------
590**Diagnostic text:**
591
592+-------------------------------------------------+---------------------------------+-------------------------------------------------------------------------+
593|:warning:`warning:` |nbsp| :diagtext:`treating #`|+-------------------------------+| |nbsp| :diagtext:`as an import of module '`:placeholder:`B`:diagtext:`'`|
594| ||:diagtext:`include` || |
595| |+-------------------------------+| |
596| ||:diagtext:`import` || |
597| |+-------------------------------+| |
598| ||:diagtext:`include\_next` || |
599| |+-------------------------------+| |
600| ||:diagtext:`\_\_include\_macros`|| |
601| |+-------------------------------+| |
602+-------------------------------------------------+---------------------------------+-------------------------------------------------------------------------+
603
604
605-Wauto-storage-class
606--------------------
607This diagnostic is enabled by default.
608
609**Diagnostic text:**
610
611+---------------------------------------------------------------------------------------------------------------------------------------------+
612|:warning:`warning:` |nbsp| :diagtext:`'auto' storage class specifier is not permitted in C++11, and will not be supported in future releases`|
613+---------------------------------------------------------------------------------------------------------------------------------------------+
614
615
616-Wauto-var-id
617-------------
618This diagnostic is enabled by default.
619
620**Diagnostic text:**
621
622+-------------------------------------------------------------------------------------------------------+
623|:warning:`warning:` |nbsp| :diagtext:`'auto' deduced as 'id' in declaration of` |nbsp| :placeholder:`A`|
624+-------------------------------------------------------------------------------------------------------+
625
626
627-Wavailability
628--------------
629This diagnostic is enabled by default.
630
631**Diagnostic text:**
632
633+--------------------------------------------------------------------------------------------------------------+
634|:warning:`warning:` |nbsp| :diagtext:`'unavailable' availability overrides all other availability information`|
635+--------------------------------------------------------------------------------------------------------------+
636
637+------------------------------------------------------------------------------------------------------------------------+
638|:warning:`warning:` |nbsp| :diagtext:`unknown platform` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in availability macro`|
639+------------------------------------------------------------------------------------------------------------------------+
640
641+----------------------------------------------------------------+------------------------+------------------------------------------------------------------------------------------------------------------------------------------+------------------------+-------------------------------------------------------------------------------------+
642|:warning:`warning:` |nbsp| :diagtext:`feature cannot be` |nbsp| |+----------------------+| |nbsp| :diagtext:`in` |nbsp| :placeholder:`B` |nbsp| :diagtext:`version` |nbsp| :placeholder:`C` |nbsp| :diagtext:`before it was` |nbsp| |+----------------------+| |nbsp| :diagtext:`in version` |nbsp| :placeholder:`E`:diagtext:`; attribute ignored`|
643| ||:diagtext:`introduced`|| ||:diagtext:`introduced`|| |
644| |+----------------------+| |+----------------------+| |
645| ||:diagtext:`deprecated`|| ||:diagtext:`deprecated`|| |
646| |+----------------------+| |+----------------------+| |
647| ||:diagtext:`obsoleted` || ||:diagtext:`obsoleted` || |
648| |+----------------------+| |+----------------------+| |
649+----------------------------------------------------------------+------------------------+------------------------------------------------------------------------------------------------------------------------------------------+------------------------+-------------------------------------------------------------------------------------+
650
651+---------------------------------------------------------------------------------------------------------------------------+
652|:warning:`warning:` |nbsp| :diagtext:`use same version number separators '\_' or '.'; as in 'major\[.minor\[.subminor\]\]'`|
653+---------------------------------------------------------------------------------------------------------------------------+
654
655+---------------------------------------------------------------------------------------+
656|:warning:`warning:` |nbsp| :diagtext:`availability does not match previous declaration`|
657+---------------------------------------------------------------------------------------+
658
659+---------------------------+--------------------------------+--------------------------+-------------------------------+--------+-----------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+
660|:warning:`warning:` |nbsp| |+------------------------------+|:diagtext:`method` |nbsp| |+-----------------------------+| |nbsp| |+---------------------------------------------+| |nbsp| :diagtext:`on` |nbsp| :placeholder:`B` |nbsp| :diagtext:`(`:placeholder:`C` |nbsp| :diagtext:`vs.` |nbsp| :placeholder:`D`:diagtext:`)`|
661| || || ||:diagtext:`introduced after` || ||:diagtext:`the protocol method it implements`|| |
662| |+------------------------------+| |+-----------------------------+| |+---------------------------------------------+| |
663| ||:diagtext:`overriding` |nbsp| || ||:diagtext:`deprecated before`|| ||:diagtext:`overridden method` || |
664| |+------------------------------+| |+-----------------------------+| |+---------------------------------------------+| |
665| | | ||:diagtext:`obsoleted before` || | | |
666| | | |+-----------------------------+| | | |
667+---------------------------+--------------------------------+--------------------------+-------------------------------+--------+-----------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+
668
669+---------------------------+--------------------------------+---------------------------------------------------------------------------------------------------+-----------------------------------------------+--------------------------------+
670|:warning:`warning:` |nbsp| |+------------------------------+|:diagtext:`method cannot be unavailable on` |nbsp| :placeholder:`A` |nbsp| :diagtext:`when` |nbsp| |+---------------------------------------------+| |nbsp| :diagtext:`is available`|
671| || || ||:diagtext:`the protocol method it implements`|| |
672| |+------------------------------+| |+---------------------------------------------+| |
673| ||:diagtext:`overriding` |nbsp| || ||:diagtext:`its overridden method` || |
674| |+------------------------------+| |+---------------------------------------------+| |
675+---------------------------+--------------------------------+---------------------------------------------------------------------------------------------------+-----------------------------------------------+--------------------------------+
676
677
678-Wbackend-plugin
679----------------
680This diagnostic is enabled by default.
681
682**Diagnostic text:**
683
684The text of this diagnostic is not controlled by Clang.
685
686
687-Wbackslash-newline-escape
688--------------------------
689This diagnostic is enabled by default.
690
691**Diagnostic text:**
692
693+-------------------------------------------------------------------------------+
694|:warning:`warning:` |nbsp| :diagtext:`backslash and newline separated by space`|
695+-------------------------------------------------------------------------------+
696
697
698-Wbad-array-new-length
699----------------------
700This diagnostic is enabled by default.
701
702**Diagnostic text:**
703
704+--------------------------------------------------------------------------------------------------------+
705|:warning:`warning:` |nbsp| :diagtext:`array is too large (`:placeholder:`A` |nbsp| :diagtext:`elements)`|
706+--------------------------------------------------------------------------------------------------------+
707
708+-------------------------------------------------------------+
709|:warning:`warning:` |nbsp| :diagtext:`array size is negative`|
710+-------------------------------------------------------------+
711
712
713-Wbad-function-cast
714-------------------
715**Diagnostic text:**
716
717+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
718|:warning:`warning:` |nbsp| :diagtext:`cast from function call of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to non-matching type` |nbsp| :placeholder:`B`|
719+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
720
721
722-Wbind-to-temporary-copy
723------------------------
724Also controls `-Wc++98-compat-bind-to-temporary-copy`_.
725
726**Diagnostic text:**
727
728+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+
729|:warning:`warning:` |nbsp| :diagtext:`C++98 requires an accessible copy constructor for class` |nbsp| :placeholder:`C` |nbsp| :diagtext:`when binding a reference to a temporary; was` |nbsp| |+---------------------+|
730| ||:diagtext:`private` ||
731| |+---------------------+|
732| ||:diagtext:`protected`||
733| |+---------------------+|
734+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+
735
736+--------------------------------------------------------------------+-----------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------+
737|:warning:`warning:` |nbsp| :diagtext:`no viable constructor` |nbsp| |+---------------------------------------+| |nbsp| :diagtext:`of type` |nbsp| :placeholder:`B`:diagtext:`; C++98 requires a copy constructor when binding a reference to a temporary`|
738| ||:diagtext:`copying variable` || |
739| |+---------------------------------------+| |
740| ||:diagtext:`copying parameter` || |
741| |+---------------------------------------+| |
742| ||:diagtext:`returning object` || |
743| |+---------------------------------------+| |
744| ||:diagtext:`throwing object` || |
745| |+---------------------------------------+| |
746| ||:diagtext:`copying member subobject` || |
747| |+---------------------------------------+| |
748| ||:diagtext:`copying array element` || |
749| |+---------------------------------------+| |
750| ||:diagtext:`allocating object` || |
751| |+---------------------------------------+| |
752| ||:diagtext:`copying temporary` || |
753| |+---------------------------------------+| |
754| ||:diagtext:`initializing base subobject`|| |
755| |+---------------------------------------+| |
756| ||:diagtext:`initializing vector element`|| |
757| |+---------------------------------------+| |
758| ||:diagtext:`capturing value` || |
759| |+---------------------------------------+| |
760+--------------------------------------------------------------------+-----------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------+
761
762
763-Wbitfield-constant-conversion
764------------------------------
765This diagnostic is enabled by default.
766
767**Diagnostic text:**
768
769+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
770|:warning:`warning:` |nbsp| :diagtext:`implicit truncation from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to bitfield changes value from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
771+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
772
773
774-Wbitfield-width
775----------------
776This diagnostic is enabled by default.
777
778**Diagnostic text:**
779
780+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+
781|:warning:`warning:` |nbsp| :diagtext:`width of anonymous bit-field (`:placeholder:`A` |nbsp| :diagtext:`bits) exceeds width of its type; value will be truncated to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`bit`|+-------------+|
782| || ||
783| |+-------------+|
784| ||:diagtext:`s`||
785| |+-------------+|
786+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+
787
788+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+
789|:warning:`warning:` |nbsp| :diagtext:`width of bit-field` |nbsp| :placeholder:`A` |nbsp| :diagtext:`(`:placeholder:`B` |nbsp| :diagtext:`bits) exceeds the width of its type; value will be truncated to` |nbsp| :placeholder:`C` |nbsp| :diagtext:`bit`|+-------------+|
790| || ||
791| |+-------------+|
792| ||:diagtext:`s`||
793| |+-------------+|
794+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------+
795
796
797-Wbitwise-op-parentheses
798------------------------
799This diagnostic is enabled by default.
800
801**Diagnostic text:**
802
803+-----------------------------------------------------------------------------------------------------------+
804|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' within '`:placeholder:`B`:diagtext:`'`|
805+-----------------------------------------------------------------------------------------------------------+
806
807
808-Wbool-conversion
809-----------------
810This diagnostic is enabled by default.
811
812Also controls `-Wpointer-bool-conversion`_, `-Wundefined-bool-conversion`_.
813
814**Diagnostic text:**
815
816+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
817|:warning:`warning:` |nbsp| :diagtext:`initialization of pointer of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to null from a constant boolean expression`|
818+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
819
820
821-Wbool-conversions
822------------------
823Synonym for `-Wbool-conversion`_.
824
825
826-Wbraced-scalar-init
827--------------------
828This diagnostic is enabled by default.
829
830**Diagnostic text:**
831
832+-----------------------------------------------------------------------+
833|:warning:`warning:` |nbsp| :diagtext:`braces around scalar initializer`|
834+-----------------------------------------------------------------------+
835
836
837-Wbridge-cast
838-------------
839This diagnostic is enabled by default.
840
841**Diagnostic text:**
842
843+------------------------------------------------------------------------------------------------------------------------------------------+
844|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`bridges to` |nbsp| :placeholder:`B`:diagtext:`, not` |nbsp| :placeholder:`C`|
845+------------------------------------------------------------------------------------------------------------------------------------------+
846
847+-------------------------------------------------------------------------------------------------------+
848|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot bridge to` |nbsp| :placeholder:`B`|
849+-------------------------------------------------------------------------------------------------------+
850
851
852-Wbuiltin-macro-redefined
853-------------------------
854This diagnostic is enabled by default.
855
856**Diagnostic text:**
857
858+---------------------------------------------------------------+
859|:warning:`warning:` |nbsp| :diagtext:`redefining builtin macro`|
860+---------------------------------------------------------------+
861
862+---------------------------------------------------------------+
863|:warning:`warning:` |nbsp| :diagtext:`undefining builtin macro`|
864+---------------------------------------------------------------+
865
866
867-Wbuiltin-memcpy-chk-size
868-------------------------
869This diagnostic is enabled by default.
870
871**Diagnostic text:**
872
873+------------------------------------------------------------------------------------------------------+
874|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will always overflow destination buffer`|
875+------------------------------------------------------------------------------------------------------+
876
877
878-Wbuiltin-requires-header
879-------------------------
880This diagnostic is enabled by default.
881
882**Diagnostic text:**
883
884+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
885|:warning:`warning:` |nbsp| :diagtext:`declaration of built-in function '`:placeholder:`B`:diagtext:`' requires inclusion of the header <`:placeholder:`A`:diagtext:`>`|
886+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
887
888
889-Wc++-compat
890------------
891**Diagnostic text:**
892
893+---------------------------+---------------------------+--------------------+--------------------------------------------+---------------------------+--------------------------+
894|:warning:`warning:` |nbsp| |+-------------------------+|+------------------+| |nbsp| :diagtext:`has size 0 in C,` |nbsp| |+-------------------------+| |nbsp| :diagtext:`in C++`|
895| || |||:diagtext:`struct`|| ||:diagtext:`size 1` || |
896| |+-------------------------+|+------------------+| |+-------------------------+| |
897| ||:diagtext:`empty` |nbsp| |||:diagtext:`union` || ||:diagtext:`non-zero size`|| |
898| |+-------------------------+|+------------------+| |+-------------------------+| |
899+---------------------------+---------------------------+--------------------+--------------------------------------------+---------------------------+--------------------------+
900
901
902-Wc++0x-compat
903--------------
904Synonym for `-Wc++11-compat`_.
905
906
907-Wc++0x-extensions
908------------------
909Synonym for `-Wc++11-extensions`_.
910
911
912-Wc++0x-narrowing
913-----------------
914Synonym for `-Wc++11-narrowing`_.
915
916
917-Wc++11-compat
918--------------
919Some of the diagnostics controlled by this flag are enabled by default.
920
921Also controls `-Wc++11-narrowing`_, `-Wc++11-compat-reserved-user-defined-literal`_, `-Wc++11-compat-deprecated-writable-strings`_, `-Wc++98-c++11-compat`_, `-Wc++98-c++11-c++14-compat`_.
922
923**Diagnostic text:**
924
925+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------------+
926|:warning:`warning:` |nbsp| :diagtext:`integer literal is too large to be represented in type 'long' and is subject to undefined behavior under C++98, interpreting as 'unsigned long'; this literal will` |nbsp| |+---------------------------------+| |nbsp| :diagtext:`in C++11 onwards`|
927| ||:diagtext:`have type 'long long'`|| |
928| |+---------------------------------+| |
929| ||:diagtext:`be ill-formed` || |
930| |+---------------------------------+| |
931+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------------+
932
933+--------------------------------------------------------------------------------------------------------------+
934|:warning:`warning:` |nbsp| :diagtext:`'auto' storage class specifier is redundant and incompatible with C++11`|
935+--------------------------------------------------------------------------------------------------------------+
936
937+-------------------------------------------------------------------------------------------------------------------------+
938|:warning:`warning:` |nbsp| :diagtext:`identifier after literal will be treated as a user-defined literal suffix in C++11`|
939+-------------------------------------------------------------------------------------------------------------------------+
940
941+-------------------------------------------------------------------------------------------+
942|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' is a keyword in C++11`|
943+-------------------------------------------------------------------------------------------+
944
945+--------------------------------------------------------------------------------------------------------------------------------+
946|:warning:`warning:` |nbsp| :diagtext:`use of right-shift operator ('>>') in template argument will require parentheses in C++11`|
947+--------------------------------------------------------------------------------------------------------------------------------+
948
949+--------------------------------------------------------------------------------+
950|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation cannot be 'inline'`|
951+--------------------------------------------------------------------------------+
952
953+--------------------------------------------------------------------------------------------------------------------------------------+
954|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`must occur at global scope`|
955+--------------------------------------------------------------------------------------------------------------------------------------+
956
957+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
958|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not in a namespace enclosing` |nbsp| :placeholder:`B`|
959+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
960
961+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
962|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`must occur in namespace` |nbsp| :placeholder:`B`|
963+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
964
965+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------------+
966|:warning:`warning:` |nbsp| :diagtext:`integer literal is too large to be represented in type 'long', interpreting as 'unsigned long' per C++98; this literal will` |nbsp| |+---------------------------------+| |nbsp| :diagtext:`in C++11 onwards`|
967| ||:diagtext:`have type 'long long'`|| |
968| |+---------------------------------+| |
969| ||:diagtext:`be ill-formed` || |
970| |+---------------------------------+| |
971+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------------+
972
973
974-Wc++11-compat-deprecated-writable-strings
975------------------------------------------
976This diagnostic is enabled by default.
977
978**Diagnostic text:**
979
980+---------------------------------------------------------------------------------------------------------------------------------+
981|:warning:`warning:` |nbsp| :diagtext:`conversion from string literal to` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is deprecated`|
982+---------------------------------------------------------------------------------------------------------------------------------+
983
984
985-Wc++11-compat-pedantic
986-----------------------
987Controls `-Wc++98-c++11-compat-pedantic`_, `-Wc++98-c++11-c++14-compat-pedantic`_.
988
989
990-Wc++11-compat-reserved-user-defined-literal
991--------------------------------------------
992**Diagnostic text:**
993
994+----------------------------------------------------------------------------------------------------------------------------------+
995|:warning:`warning:` |nbsp| :diagtext:`identifier after literal will be treated as a reserved user-defined literal suffix in C++11`|
996+----------------------------------------------------------------------------------------------------------------------------------+
997
998
999-Wc++11-extensions
1000------------------
1001Some of the diagnostics controlled by this flag are enabled by default.
1002
1003Also controls `-Wc++11-extra-semi`_, `-Wc++11-inline-namespace`_, `-Wc++11-long-long`_.
1004
1005**Diagnostic text:**
1006
1007+-------------------------------------------------------------------------------+
1008|:warning:`warning:` |nbsp| :diagtext:`alias declarations are a C++11 extension`|
1009+-------------------------------------------------------------------------------+
1010
1011+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------+
1012|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from array size expression of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| |+-----------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is a C++11 extension`|
1013| ||:diagtext:`integral` || |
1014| |+-----------------------+| |
1015| ||:diagtext:`enumeration`|| |
1016| |+-----------------------+| |
1017+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------+
1018
1019+---------------------------------------------------------------------------------+
1020|:warning:`warning:` |nbsp| :diagtext:`'auto' type specifier is a C++11 extension`|
1021+---------------------------------------------------------------------------------+
1022
1023+-----------------------------------------------------------------------------------------------------------+
1024|:warning:`warning:` |nbsp| :diagtext:`enumeration types with a fixed underlying type are a C++11 extension`|
1025+-----------------------------------------------------------------------------------------------------------+
1026
1027+---------------------------+-----------------------+--------------------------------------------------------------+
1028|:warning:`warning:` |nbsp| |+---------------------+| |nbsp| :diagtext:`function definitions are a C++11 extension`|
1029| ||:diagtext:`defaulted`|| |
1030| |+---------------------+| |
1031| ||:diagtext:`deleted` || |
1032| |+---------------------+| |
1033+---------------------------+-----------------------+--------------------------------------------------------------+
1034
1035+-----------------------------------------------------------------------------------------------------------------------------------+
1036|:warning:`warning:` |nbsp| :diagtext:`befriending enumeration type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a C++11 extension`|
1037+-----------------------------------------------------------------------------------------------------------------------------------+
1038
1039+--------------------------------------------------------------------------------------------------+
1040|:warning:`warning:` |nbsp| :diagtext:`commas at the end of enumerator lists are a C++11 extension`|
1041+--------------------------------------------------------------------------------------------------+
1042
1043+------------------------------------------------------------------------------------------+
1044|:warning:`warning:` |nbsp| :diagtext:`explicit conversion functions are a C++11 extension`|
1045+------------------------------------------------------------------------------------------+
1046
1047+-----------------------------------------------------------------------------+
1048|:warning:`warning:` |nbsp| :diagtext:`extern templates are a C++11 extension`|
1049+-----------------------------------------------------------------------------+
1050
1051+--------------------------------------------------------------------------------+
1052|:warning:`warning:` |nbsp| :diagtext:`range-based for loop is a C++11 extension`|
1053+--------------------------------------------------------------------------------+
1054
1055+------------------------------------------------------------------------------------------+
1056|:warning:`warning:` |nbsp| :diagtext:`generalized initializer lists are a C++11 extension`|
1057+------------------------------------------------------------------------------------------+
1058
1059+---------------------------------------------------------------------------------------------------------+
1060|:warning:`warning:` |nbsp| :diagtext:`use of enumeration in a nested name specifier is a C++11 extension`|
1061+---------------------------------------------------------------------------------------------------------+
1062
1063+----------------------------------------------------------------------------------------------------------------------------+
1064|:warning:`warning:` |nbsp| :diagtext:`non-class friend type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a C++11 extension`|
1065+----------------------------------------------------------------------------------------------------------------------------+
1066
1067+-------------------------------------------------------------------------------------------------------------+
1068|:warning:`warning:` |nbsp| :diagtext:`in-class initialization of non-static data member is a C++11 extension`|
1069+-------------------------------------------------------------------------------------------------------------+
1070
1071+--------------------------------------------------------------------------------------------------+
1072|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' keyword is a C++11 extension`|
1073+--------------------------------------------------------------------------------------------------+
1074
1075+----------------------------------------------------------------------------------------------+
1076|:warning:`warning:` |nbsp| :diagtext:`reference qualifiers on functions are a C++11 extension`|
1077+----------------------------------------------------------------------------------------------+
1078
1079+------------------------------------------------------------------------------+
1080|:warning:`warning:` |nbsp| :diagtext:`rvalue references are a C++11 extension`|
1081+------------------------------------------------------------------------------+
1082
1083+--------------------------------------------------------------------------------+
1084|:warning:`warning:` |nbsp| :diagtext:`scoped enumerations are a C++11 extension`|
1085+--------------------------------------------------------------------------------+
1086
1087+----------------------------------------------------------------------------------------------------------------------------------+
1088|:warning:`warning:` |nbsp| :diagtext:`static data member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in union is a C++11 extension`|
1089+----------------------------------------------------------------------------------------------------------------------------------+
1090
1091+--------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------+
1092|:warning:`warning:` |nbsp| :diagtext:`non-type template argument referring to` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`with internal linkage is a C++11 extension`|
1093| ||:diagtext:`function`|| |
1094| |+--------------------+| |
1095| ||:diagtext:`object` || |
1096| |+--------------------+| |
1097+--------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------+
1098
1099+-------------------------------------------------------------------------------+
1100|:warning:`warning:` |nbsp| :diagtext:`'template' keyword outside of a template`|
1101+-------------------------------------------------------------------------------+
1102
1103+---------------------------------------------------------------------------------------------------------------+
1104|:warning:`warning:` |nbsp| :diagtext:`default template arguments for a function template are a C++11 extension`|
1105+---------------------------------------------------------------------------------------------------------------+
1106
1107+-------------------------------------------------------------------+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1108|:warning:`warning:` |nbsp| :diagtext:`first declaration of` |nbsp| |+-------------------------------------+| |nbsp| :diagtext:`specialization of` |nbsp| :placeholder:`B` |nbsp| :diagtext:`outside namespace` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is a C++11 extension`|
1109| ||:diagtext:`class template` || |
1110| |+-------------------------------------+| |
1111| ||:diagtext:`class template partial` || |
1112| |+-------------------------------------+| |
1113| ||:diagtext:`variable template` || |
1114| |+-------------------------------------+| |
1115| ||:diagtext:`variable template partial`|| |
1116| |+-------------------------------------+| |
1117| ||:diagtext:`function template` || |
1118| |+-------------------------------------+| |
1119| ||:diagtext:`member function` || |
1120| |+-------------------------------------+| |
1121| ||:diagtext:`static data member` || |
1122| |+-------------------------------------+| |
1123| ||:diagtext:`member class` || |
1124| |+-------------------------------------+| |
1125| ||:diagtext:`member enumeration` || |
1126| |+-------------------------------------+| |
1127+-------------------------------------------------------------------+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1128
1129+------------------------------------------------------------------------------+
1130|:warning:`warning:` |nbsp| :diagtext:`'typename' occurs outside of a template`|
1131+------------------------------------------------------------------------------+
1132
1133+------------------------------------------------------------------------------------------------------+-----------------------+-------------------------------------------------+
1134|:warning:`warning:` |nbsp| :diagtext:`unelaborated friend declaration is a C++11 extension; specify '`|+---------------------+|:diagtext:`' to befriend` |nbsp| :placeholder:`B`|
1135| ||:diagtext:`struct` || |
1136| |+---------------------+| |
1137| ||:diagtext:`interface`|| |
1138| |+---------------------+| |
1139| ||:diagtext:`union` || |
1140| |+---------------------+| |
1141| ||:diagtext:`class` || |
1142| |+---------------------+| |
1143| ||:diagtext:`enum` || |
1144| |+---------------------+| |
1145+------------------------------------------------------------------------------------------------------+-----------------------+-------------------------------------------------+
1146
1147+-------------------------------------------------------------------------------+
1148|:warning:`warning:` |nbsp| :diagtext:`variadic templates are a C++11 extension`|
1149+-------------------------------------------------------------------------------+
1150
1151
1152-Wc++11-extra-semi
1153------------------
1154**Diagnostic text:**
1155
1156+-------------------------------------------------------------------------------------------+
1157|:warning:`warning:` |nbsp| :diagtext:`extra ';' outside of a function is a C++11 extension`|
1158+-------------------------------------------------------------------------------------------+
1159
1160
1161-Wc++11-inline-namespace
1162------------------------
1163This diagnostic is enabled by default.
1164
1165**Diagnostic text:**
1166
1167+----------------------------------------------------------------------------+
1168|:warning:`warning:` |nbsp| :diagtext:`inline namespaces are a C++11 feature`|
1169+----------------------------------------------------------------------------+
1170
1171
1172-Wc++11-long-long
1173-----------------
1174**Diagnostic text:**
1175
1176+-----------------------------------------------------------------------+
1177|:warning:`warning:` |nbsp| :diagtext:`'long long' is a C++11 extension`|
1178+-----------------------------------------------------------------------+
1179
1180
1181-Wc++11-narrowing
1182-----------------
1183Some of the diagnostics controlled by this flag are enabled by default.
1184
1185**Diagnostic text:**
1186
1187+-----------------------+----------------------------------------+--------+--------------------------------------------------------------------------------------------------------------------------+
1188|:error:`error:` |nbsp| |+--------------------------------------+| |nbsp| |+------------------------------------------------------------------------------------------------------------------------+|
1189| ||:diagtext:`case value` || ||+--------------------------------------------------------------------------------------------------------------+ ||
1190| |+--------------------------------------+| |||:diagtext:`cannot be narrowed from type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D`| ||
1191| ||:diagtext:`enumerator value` || ||+--------------------------------------------------------------------------------------------------------------+ ||
1192| |+--------------------------------------+| |+------------------------------------------------------------------------------------------------------------------------+|
1193| ||:diagtext:`non-type template argument`|| ||+----------------------------------------------------------------------------------------------------------------------+||
1194| |+--------------------------------------+| |||:diagtext:`evaluates to` |nbsp| :placeholder:`C`:diagtext:`, which cannot be narrowed to type` |nbsp| :placeholder:`D`|||
1195| ||:diagtext:`array size` || ||+----------------------------------------------------------------------------------------------------------------------+||
1196| |+--------------------------------------+| |+------------------------------------------------------------------------------------------------------------------------+|
1197| ||:diagtext:`constexpr if condition` || | |
1198| |+--------------------------------------+| | |
1199+-----------------------+----------------------------------------+--------+--------------------------------------------------------------------------------------------------------------------------+
1200
1201+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1202|:error:`error:` |nbsp| :diagtext:`constant expression evaluates to` |nbsp| :placeholder:`A` |nbsp| :diagtext:`which cannot be narrowed to type` |nbsp| :placeholder:`B`|
1203+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1204
1205+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1206|:error:`error:` |nbsp| :diagtext:`type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be narrowed to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`in initializer list`|
1207+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1208
1209+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1210|:error:`error:` |nbsp| :diagtext:`non-constant-expression cannot be narrowed from type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`in initializer list`|
1211+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1212
1213+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1214|:warning:`warning:` |nbsp| :diagtext:`constant expression evaluates to` |nbsp| :placeholder:`A` |nbsp| :diagtext:`which cannot be narrowed to type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`in C++11`|
1215+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1216
1217+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1218|:warning:`warning:` |nbsp| :diagtext:`type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be narrowed to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`in initializer list in C++11`|
1219+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1220
1221+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1222|:warning:`warning:` |nbsp| :diagtext:`non-constant-expression cannot be narrowed from type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`in initializer list in C++11`|
1223+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1224
1225
1226-Wc++14-binary-literal
1227----------------------
1228**Diagnostic text:**
1229
1230+------------------------------------------------------------------------------------+
1231|:warning:`warning:` |nbsp| :diagtext:`binary integer literals are a C++14 extension`|
1232+------------------------------------------------------------------------------------+
1233
1234
1235-Wc++14-compat
1236--------------
1237Synonym for `-Wc++98-c++11-c++14-compat`_.
1238
1239
1240-Wc++14-compat-pedantic
1241-----------------------
1242Synonym for `-Wc++98-c++11-c++14-compat-pedantic`_.
1243
1244
1245-Wc++14-extensions
1246------------------
1247Some of the diagnostics controlled by this flag are enabled by default.
1248
1249Also controls `-Wc++14-binary-literal`_.
1250
1251**Diagnostic text:**
1252
1253+-----------------------------------------------------------------------------------+-------------------------+----------------------------------------+
1254|:warning:`warning:` |nbsp| :diagtext:`use of this statement in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is a C++14 extension`|
1255| ||:diagtext:`function` || |
1256| |+-----------------------+| |
1257| ||:diagtext:`constructor`|| |
1258| |+-----------------------+| |
1259+-----------------------------------------------------------------------------------+-------------------------+----------------------------------------+
1260
1261+------------------------------------------------------------------------------------------------------------+
1262|:warning:`warning:` |nbsp| :diagtext:`multiple return statements in constexpr function is a C++14 extension`|
1263+------------------------------------------------------------------------------------------------------------+
1264
1265+----------------------------------------------------------------------------------+-------------------------+----------------------------------------+
1266|:warning:`warning:` |nbsp| :diagtext:`variable declaration in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is a C++14 extension`|
1267| ||:diagtext:`function` || |
1268| |+-----------------------+| |
1269| ||:diagtext:`constructor`|| |
1270| |+-----------------------+| |
1271+----------------------------------------------------------------------------------+-------------------------+----------------------------------------+
1272
1273+-----------------------------------------------------------------------------+-------------------------+----------------------------------------+
1274|:warning:`warning:` |nbsp| :diagtext:`type definition in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is a C++14 extension`|
1275| ||:diagtext:`function` || |
1276| |+-----------------------+| |
1277| ||:diagtext:`constructor`|| |
1278| |+-----------------------+| |
1279+-----------------------------------------------------------------------------+-------------------------+----------------------------------------+
1280
1281+---------------------------------------------------------------------------------------------------------------------------+
1282|:warning:`warning:` |nbsp| :diagtext:`use of the` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute is a C++14 extension`|
1283+---------------------------------------------------------------------------------------------------------------------------+
1284
1285+-------------------------------------------------------------------------------------------+
1286|:warning:`warning:` |nbsp| :diagtext:`'decltype(auto)' type specifier is a C++14 extension`|
1287+-------------------------------------------------------------------------------------------+
1288
1289+----------------------------------------------------------------------------------------+
1290|:warning:`warning:` |nbsp| :diagtext:`initialized lambda captures are a C++14 extension`|
1291+----------------------------------------------------------------------------------------+
1292
1293+-------------------------------------------------------------------------------+
1294|:warning:`warning:` |nbsp| :diagtext:`variable templates are a C++14 extension`|
1295+-------------------------------------------------------------------------------+
1296
1297
1298-Wc++1y-extensions
1299------------------
1300Synonym for `-Wc++14-extensions`_.
1301
1302
1303-Wc++1z-compat
1304--------------
1305This diagnostic is enabled by default.
1306
1307Controls `-Wdeprecated-register`_, `-Wdeprecated-increment-bool`_.
1308
1309
1310-Wc++1z-extensions
1311------------------
1312Some of the diagnostics controlled by this flag are enabled by default.
1313
1314**Diagnostic text:**
1315
1316+------------------------------------------------------------------------+
1317|:warning:`warning:` |nbsp| :diagtext:`constexpr if is a C++1z extension`|
1318+------------------------------------------------------------------------+
1319
1320+---------------------------------------------------------------------------------------------+
1321|:warning:`warning:` |nbsp| :diagtext:`'constexpr' on lambda expressions is a C++1z extension`|
1322+---------------------------------------------------------------------------------------------+
1323
1324+---------------------------------------------------------------------------------------------------------------------------+
1325|:warning:`warning:` |nbsp| :diagtext:`use of the` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute is a C++1z extension`|
1326+---------------------------------------------------------------------------------------------------------------------------+
1327
1328+---------------------------------------------------------------------------------------+
1329|:warning:`warning:` |nbsp| :diagtext:`decomposition declarations are a C++1z extension`|
1330+---------------------------------------------------------------------------------------+
1331
1332+--------------------------------------------------------------------------------+
1333|:warning:`warning:` |nbsp| :diagtext:`pack fold expression is a C++1z extension`|
1334+--------------------------------------------------------------------------------+
1335
1336+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1337|:warning:`warning:` |nbsp| :diagtext:`'begin' and 'end' returning different types (`:placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`:diagtext:`) is a C++1z extension`|
1338+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1339
1340+----------------------------------------------------------------------------------------+
1341|:warning:`warning:` |nbsp| :diagtext:`hexadecimal floating literals are a C++1z feature`|
1342+----------------------------------------------------------------------------------------+
1343
1344+-----------------------------------------------------------------------------+
1345|:warning:`warning:` |nbsp| :diagtext:`inline variables are a C++1z extension`|
1346+-----------------------------------------------------------------------------+
1347
1348+-------------------------------------------------------------------------------------------------------------------------+
1349|:warning:`warning:` |nbsp| :diagtext:`nested namespace definition is a C++1z extension; define each namespace separately`|
1350+-------------------------------------------------------------------------------------------------------------------------+
1351
1352+---------------------------------------------------------------------------------------+
1353|:warning:`warning:` |nbsp| :diagtext:`capture of '\*this' by copy is a C++1z extension`|
1354+---------------------------------------------------------------------------------------+
1355
1356+------------------------------------------------------------------------------------------+
1357|:warning:`warning:` |nbsp| :diagtext:`static\_assert with no message is a C++1z extension`|
1358+------------------------------------------------------------------------------------------+
1359
1360+--------------------------------------------------------------------------------------------------------+
1361|:warning:`warning:` |nbsp| :diagtext:`template template parameter using 'typename' is a C++1z extension`|
1362+--------------------------------------------------------------------------------------------------------+
1363
1364+--------------------------------------------------------------------------------------------------+
1365|:warning:`warning:` |nbsp| :diagtext:`default scope specifier for attributes is a C++1z extension`|
1366+--------------------------------------------------------------------------------------------------+
1367
1368
1369-Wc++98-c++11-c++14-compat
1370--------------------------
1371**Diagnostic text:**
1372
1373+------------------------------------------------------------+---------------------------+--------------------------------------------------------------------------------+
1374|:warning:`warning:` |nbsp| :diagtext:`attributes on` |nbsp| |+-------------------------+| |nbsp| :diagtext:`declaration are incompatible with C++ standards before C++1z`|
1375| ||:diagtext:`a namespace` || |
1376| |+-------------------------+| |
1377| ||:diagtext:`an enumerator`|| |
1378| |+-------------------------+| |
1379+------------------------------------------------------------+---------------------------+--------------------------------------------------------------------------------+
1380
1381+---------------------------------------------------------------------------------------------------+
1382|:warning:`warning:` |nbsp| :diagtext:`constexpr if is incompatible with C++ standards before C++1z`|
1383+---------------------------------------------------------------------------------------------------+
1384
1385+----------------------------------------------------------------------------------------------------------------------+
1386|:warning:`warning:` |nbsp| :diagtext:`constexpr on lambda expressions is incompatible with C++ standards before C++1z`|
1387+----------------------------------------------------------------------------------------------------------------------+
1388
1389+------------------------------------------------------------------------------------------------------------------+
1390|:warning:`warning:` |nbsp| :diagtext:`decomposition declarations are incompatible with C++ standards before C++1z`|
1391+------------------------------------------------------------------------------------------------------------------+
1392
1393+-----------------------------------------------------------------------------------------------------------+
1394|:warning:`warning:` |nbsp| :diagtext:`pack fold expression is incompatible with C++ standards before C++1z`|
1395+-----------------------------------------------------------------------------------------------------------+
1396
1397+--------------------------------------------------------------------------------------------------------+
1398|:warning:`warning:` |nbsp| :diagtext:`inline variables are incompatible with C++ standards before C++1z`|
1399+--------------------------------------------------------------------------------------------------------+
1400
1401+------------------------------------------------------------------------------------------------------------------+
1402|:warning:`warning:` |nbsp| :diagtext:`nested namespace definition is incompatible with C++ standards before C++1z`|
1403+------------------------------------------------------------------------------------------------------------------+
1404
1405+-------------------------------------------------------------------------------------------------------------------+
1406|:warning:`warning:` |nbsp| :diagtext:`by value capture of '\*this' is incompatible with C++ standards before C++1z`|
1407+-------------------------------------------------------------------------------------------------------------------+
1408
1409+---------------------------------------------------------------------------------------------------------------------+
1410|:warning:`warning:` |nbsp| :diagtext:`static\_assert with no message is incompatible with C++ standards before C++1z`|
1411+---------------------------------------------------------------------------------------------------------------------+
1412
1413+-----------------------------------------------------------------------------------------------------------------------------------+
1414|:warning:`warning:` |nbsp| :diagtext:`template template parameter using 'typename' is incompatible with C++ standards before C++1z`|
1415+-----------------------------------------------------------------------------------------------------------------------------------+
1416
1417+--------------------------------------------------------------------------------------------------------+
1418|:warning:`warning:` |nbsp| :diagtext:`unicode literals are incompatible with C++ standards before C++1z`|
1419+--------------------------------------------------------------------------------------------------------+
1420
1421+-----------------------------------------------------------------------------------------------------------------------------+
1422|:warning:`warning:` |nbsp| :diagtext:`default scope specifier for attributes is incompatible with C++ standards before C++1z`|
1423+-----------------------------------------------------------------------------------------------------------------------------+
1424
1425+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1426|:warning:`warning:` |nbsp| :diagtext:`'begin' and 'end' returning different types (`:placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`:diagtext:`) is incompatible with C++ standards before C++1z`|
1427+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1428
1429
1430-Wc++98-c++11-c++14-compat-pedantic
1431-----------------------------------
1432Also controls `-Wc++98-c++11-c++14-compat`_.
1433
1434**Diagnostic text:**
1435
1436+---------------------------------------------------------------------------------------------------------------------+
1437|:warning:`warning:` |nbsp| :diagtext:`hexidecimal floating literals are incompatible with C++ standards before C++1z`|
1438+---------------------------------------------------------------------------------------------------------------------+
1439
1440
1441-Wc++98-c++11-compat
1442--------------------
1443**Diagnostic text:**
1444
1445+-----------------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1446|:warning:`warning:` |nbsp| :diagtext:`use of this statement in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is incompatible with C++ standards before C++14`|
1447| ||:diagtext:`function` || |
1448| |+-----------------------+| |
1449| ||:diagtext:`constructor`|| |
1450| |+-----------------------+| |
1451+-----------------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1452
1453+---------------------------------------------------------------------------------------------------------------------------------------+
1454|:warning:`warning:` |nbsp| :diagtext:`multiple return statements in constexpr function is incompatible with C++ standards before C++14`|
1455+---------------------------------------------------------------------------------------------------------------------------------------+
1456
1457+-----------------------------------------------------------------------------------------------------------------------------------+
1458|:warning:`warning:` |nbsp| :diagtext:`constexpr function with no return statements is incompatible with C++ standards before C++14`|
1459+-----------------------------------------------------------------------------------------------------------------------------------+
1460
1461+----------------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1462|:warning:`warning:` |nbsp| :diagtext:`variable declaration in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is incompatible with C++ standards before C++14`|
1463| ||:diagtext:`function` || |
1464| |+-----------------------+| |
1465| ||:diagtext:`constructor`|| |
1466| |+-----------------------+| |
1467+----------------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1468
1469+-----------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1470|:warning:`warning:` |nbsp| :diagtext:`type definition in a constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is incompatible with C++ standards before C++14`|
1471| ||:diagtext:`function` || |
1472| |+-----------------------+| |
1473| ||:diagtext:`constructor`|| |
1474| |+-----------------------+| |
1475+-----------------------------------------------------------------------------+-------------------------+-------------------------------------------------------------------+
1476
1477+----------------------------------------------------------------------------------------------------------------------+
1478|:warning:`warning:` |nbsp| :diagtext:`'decltype(auto)' type specifier is incompatible with C++ standards before C++14`|
1479+----------------------------------------------------------------------------------------------------------------------+
1480
1481+--------------------------------------------------------------------------------------------------------+
1482|:warning:`warning:` |nbsp| :diagtext:`digit separators are incompatible with C++ standards before C++14`|
1483+--------------------------------------------------------------------------------------------------------+
1484
1485+-------------------------------------------------------------------------------------------------------------------+
1486|:warning:`warning:` |nbsp| :diagtext:`initialized lambda captures are incompatible with C++ standards before C++14`|
1487+-------------------------------------------------------------------------------------------------------------------+
1488
1489+----------------------------------------------------------------------------------------------------------+
1490|:warning:`warning:` |nbsp| :diagtext:`variable templates are incompatible with C++ standards before C++14`|
1491+----------------------------------------------------------------------------------------------------------+
1492
1493
1494-Wc++98-c++11-compat-pedantic
1495-----------------------------
1496Also controls `-Wc++98-c++11-compat`_.
1497
1498**Diagnostic text:**
1499
1500+---------------------------------------------------------------------------------------------------------------+
1501|:warning:`warning:` |nbsp| :diagtext:`binary integer literals are incompatible with C++ standards before C++14`|
1502+---------------------------------------------------------------------------------------------------------------+
1503
1504
1505-Wc++98-compat
1506--------------
1507Also controls `-Wc++98-compat-local-type-template-args`_, `-Wc++98-compat-unnamed-type-template-args`_, `-Wc++98-c++11-compat`_, `-Wc++98-c++11-c++14-compat`_.
1508
1509**Diagnostic text:**
1510
1511+-------------------------------------------------------------------------------------+
1512|:warning:`warning:` |nbsp| :diagtext:`alias declarations are incompatible with C++98`|
1513+-------------------------------------------------------------------------------------+
1514
1515+---------------------------------------------------------------------------+
1516|:warning:`warning:` |nbsp| :diagtext:`'alignas' is incompatible with C++98`|
1517+---------------------------------------------------------------------------+
1518
1519+--------------------------------------------------------------------------------------+
1520|:warning:`warning:` |nbsp| :diagtext:`alignof expressions are incompatible with C++98`|
1521+--------------------------------------------------------------------------------------+
1522
1523+----------------------------------------------------------------------------------------+
1524|:warning:`warning:` |nbsp| :diagtext:`C++11 attribute syntax is incompatible with C++98`|
1525+----------------------------------------------------------------------------------------+
1526
1527+---------------------------------------------------------------------------------------+
1528|:warning:`warning:` |nbsp| :diagtext:`'auto' type specifier is incompatible with C++98`|
1529+---------------------------------------------------------------------------------------+
1530
1531+---------------------------------------------------------------------------------------+
1532|:warning:`warning:` |nbsp| :diagtext:`'constexpr' specifier is incompatible with C++98`|
1533+---------------------------------------------------------------------------------------+
1534
1535+--------------------------------------------------------------------------------------------------------+
1536|:warning:`warning:` |nbsp| :diagtext:`constructor call from initializer list is incompatible with C++98`|
1537+--------------------------------------------------------------------------------------------------------+
1538
1539+-------------------------------------------------------------------------------------------+
1540|:warning:`warning:` |nbsp| :diagtext:`'decltype' type specifier is incompatible with C++98`|
1541+-------------------------------------------------------------------------------------------+
1542
1543+---------------------------+-----------------------+--------------------------------------------------------------------+
1544|:warning:`warning:` |nbsp| |+---------------------+| |nbsp| :diagtext:`function definitions are incompatible with C++98`|
1545| ||:diagtext:`defaulted`|| |
1546| |+---------------------+| |
1547| ||:diagtext:`deleted` || |
1548| |+---------------------+| |
1549+---------------------------+-----------------------+--------------------------------------------------------------------+
1550
1551+------------------------------------------------------------------------------------------+
1552|:warning:`warning:` |nbsp| :diagtext:`delegating constructors are incompatible with C++98`|
1553+------------------------------------------------------------------------------------------+
1554
1555+----------------------------------------------------------------------------------------------------------------+
1556|:warning:`warning:` |nbsp| :diagtext:`scalar initialized from empty initializer list is incompatible with C++98`|
1557+----------------------------------------------------------------------------------------------------------------+
1558
1559+-----------------------------------------------------------------------------------------------------------------+
1560|:warning:`warning:` |nbsp| :diagtext:`enumeration types with a fixed underlying type are incompatible with C++98`|
1561+-----------------------------------------------------------------------------------------------------------------+
1562
1563+-----------------------------------------------------------------------------------------------------------------------------------------+
1564|:warning:`warning:` |nbsp| :diagtext:`befriending enumeration type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is incompatible with C++98`|
1565+-----------------------------------------------------------------------------------------------------------------------------------------+
1566
1567+-----------------------------------------------------------------------------------------------------------+
1568|:warning:`warning:` |nbsp| :diagtext:`enumeration type in nested name specifier is incompatible with C++98`|
1569+-----------------------------------------------------------------------------------------------------------+
1570
1571+------------------------------------------------------------------------------------------------+
1572|:warning:`warning:` |nbsp| :diagtext:`explicit conversion functions are incompatible with C++98`|
1573+------------------------------------------------------------------------------------------------+
1574
1575+--------------------------------------------------------------------------------------+
1576|:warning:`warning:` |nbsp| :diagtext:`range-based for loop is incompatible with C++98`|
1577+--------------------------------------------------------------------------------------+
1578
1579+---------------------------------------------------------------------------------------------------------------------------+
1580|:warning:`warning:` |nbsp| :diagtext:`friend declaration naming a member of the declaring class is incompatible with C++98`|
1581+---------------------------------------------------------------------------------------------------------------------------+
1582
1583+------------------------------------------------------------------------------------------------+
1584|:warning:`warning:` |nbsp| :diagtext:`generalized initializer lists are incompatible with C++98`|
1585+------------------------------------------------------------------------------------------------+
1586
1587+------------------------------------------------------------------------------------------------------------+
1588|:warning:`warning:` |nbsp| :diagtext:`jump from this goto statement to its label is incompatible with C++98`|
1589+------------------------------------------------------------------------------------------------------------+
1590
1591+---------------------------------------------------------------------------------------------------------------------------------------+
1592|:warning:`warning:` |nbsp| :diagtext:`jump from this indirect goto statement to one of its possible targets is incompatible with C++98`|
1593+---------------------------------------------------------------------------------------------------------------------------------------+
1594
1595+------------------------------------------------------------------------------------------------------------+
1596|:warning:`warning:` |nbsp| :diagtext:`initialization of initializer\_list object is incompatible with C++98`|
1597+------------------------------------------------------------------------------------------------------------+
1598
1599+------------------------------------------------------------------------------------+
1600|:warning:`warning:` |nbsp| :diagtext:`inline namespaces are incompatible with C++98`|
1601+------------------------------------------------------------------------------------+
1602
1603+-------------------------------------------------------------------------------------+
1604|:warning:`warning:` |nbsp| :diagtext:`lambda expressions are incompatible with C++98`|
1605+-------------------------------------------------------------------------------------+
1606
1607+-----------------------------------------------------------------------------------------------------------+
1608|:warning:`warning:` |nbsp| :diagtext:`'<::' is treated as digraph '<:' (aka '\[') followed by ':' in C++98`|
1609+-----------------------------------------------------------------------------------------------------------+
1610
1611+------------------------------------------------------------------------------------+
1612|:warning:`warning:` |nbsp| :diagtext:`literal operators are incompatible with C++98`|
1613+------------------------------------------------------------------------------------+
1614
1615+---------------------------------------------------------------------------------------------------------------------------+
1616|:warning:`warning:` |nbsp| :diagtext:`universal character name referring to a control character is incompatible with C++98`|
1617+---------------------------------------------------------------------------------------------------------------------------+
1618
1619+-----------------------------------------------------------------------------------------------------------------------------------------------------+
1620|:warning:`warning:` |nbsp| :diagtext:`specifying character '`:placeholder:`A`:diagtext:`' with a universal character name is incompatible with C++98`|
1621+-----------------------------------------------------------------------------------------------------------------------------------------------------+
1622
1623+------------------------------------------------------------------------------------------+
1624|:warning:`warning:` |nbsp| :diagtext:`noexcept specifications are incompatible with C++98`|
1625+------------------------------------------------------------------------------------------+
1626
1627+---------------------------------------------------------------------------------------+
1628|:warning:`warning:` |nbsp| :diagtext:`noexcept expressions are incompatible with C++98`|
1629+---------------------------------------------------------------------------------------+
1630
1631+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1632|:warning:`warning:` |nbsp| :diagtext:`use of non-static data member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in an unevaluated context is incompatible with C++98`|
1633+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1634
1635+----------------------------------------------------------------------------------------------------------------------------------+
1636|:warning:`warning:` |nbsp| :diagtext:`non-class friend type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is incompatible with C++98`|
1637+----------------------------------------------------------------------------------------------------------------------------------+
1638
1639+--------------------------------------------------------------------------------------------------------------------+
1640|:warning:`warning:` |nbsp| :diagtext:`in-class initialization of non-static data members is incompatible with C++98`|
1641+--------------------------------------------------------------------------------------------------------------------+
1642
1643+---------------------------+------------------------------+------------------------------------------------------------------------------------------------+--------------------------------------+----------------------------------------------+
1644|:warning:`warning:` |nbsp| |+----------------------------+| |nbsp| :diagtext:`member` |nbsp| :placeholder:`B` |nbsp| :diagtext:`with a non-trivial` |nbsp| |+------------------------------------+| |nbsp| :diagtext:`is incompatible with C++98`|
1645| ||:diagtext:`anonymous struct`|| ||:diagtext:`constructor` || |
1646| |+----------------------------+| |+------------------------------------+| |
1647| ||:diagtext:`union` || ||:diagtext:`copy constructor` || |
1648| |+----------------------------+| |+------------------------------------+| |
1649| | | ||:diagtext:`move constructor` || |
1650| | | |+------------------------------------+| |
1651| | | ||:diagtext:`copy assignment operator`|| |
1652| | | |+------------------------------------+| |
1653| | | ||:diagtext:`move assignment operator`|| |
1654| | | |+------------------------------------+| |
1655| | | ||:diagtext:`destructor` || |
1656| | | |+------------------------------------+| |
1657+---------------------------+------------------------------+------------------------------------------------------------------------------------------------+--------------------------------------+----------------------------------------------+
1658
1659+---------------------------------------------------------------------------+
1660|:warning:`warning:` |nbsp| :diagtext:`'nullptr' is incompatible with C++98`|
1661+---------------------------------------------------------------------------+
1662
1663+--------------------------------------------------------------------------------------------------------+
1664|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' keyword is incompatible with C++98`|
1665+--------------------------------------------------------------------------------------------------------+
1666
1667+-----------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------+
1668|:warning:`warning:` |nbsp| :diagtext:`passing object of trivial but non-POD type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`through variadic` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is incompatible with C++98`|
1669| ||:diagtext:`function` || |
1670| |+-----------------------+| |
1671| ||:diagtext:`block` || |
1672| |+-----------------------+| |
1673| ||:diagtext:`method` || |
1674| |+-----------------------+| |
1675| ||:diagtext:`constructor`|| |
1676| |+-----------------------+| |
1677+-----------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------+
1678
1679+--------------------------------------------------------------------------------------+
1680|:warning:`warning:` |nbsp| :diagtext:`raw string literals are incompatible with C++98`|
1681+--------------------------------------------------------------------------------------+
1682
1683+----------------------------------------------------------------------------------------------------+
1684|:warning:`warning:` |nbsp| :diagtext:`reference qualifiers on functions are incompatible with C++98`|
1685+----------------------------------------------------------------------------------------------------+
1686
1687+-------------------------------------------------------------------------------------------------------------+
1688|:warning:`warning:` |nbsp| :diagtext:`reference initialized from initializer list is incompatible with C++98`|
1689+-------------------------------------------------------------------------------------------------------------+
1690
1691+------------------------------------------------------------------------------------+
1692|:warning:`warning:` |nbsp| :diagtext:`rvalue references are incompatible with C++98`|
1693+------------------------------------------------------------------------------------+
1694
1695+--------------------------------------------------------------------------------------+
1696|:warning:`warning:` |nbsp| :diagtext:`scoped enumerations are incompatible with C++98`|
1697+--------------------------------------------------------------------------------------+
1698
1699+------------------------------------------------------------------------------------------------------------+
1700|:warning:`warning:` |nbsp| :diagtext:`substitution failure due to access control is incompatible with C++98`|
1701+------------------------------------------------------------------------------------------------------------+
1702
1703+----------------------------------------------------------------------------------------------+
1704|:warning:`warning:` |nbsp| :diagtext:`static\_assert declarations are incompatible with C++98`|
1705+----------------------------------------------------------------------------------------------+
1706
1707+----------------------------------------------------------------------------------------------------------------------------------------+
1708|:warning:`warning:` |nbsp| :diagtext:`static data member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in union is incompatible with C++98`|
1709+----------------------------------------------------------------------------------------------------------------------------------------+
1710
1711+---------------------------------------------------------------------------------------------------------------+
1712|:warning:`warning:` |nbsp| :diagtext:`jump from switch statement to this case label is incompatible with C++98`|
1713+---------------------------------------------------------------------------------------------------------------+
1714
1715+---------------------------------------------------------------------------------------------------------------------------------------+
1716|:warning:`warning:` |nbsp| :diagtext:`redundant parentheses surrounding address non-type template argument are incompatible with C++98`|
1717+---------------------------------------------------------------------------------------------------------------------------------------+
1718
1719+-------------------------------------------------------------------------------------------------------------------+
1720|:warning:`warning:` |nbsp| :diagtext:`use of null pointer as non-type template argument is incompatible with C++98`|
1721+-------------------------------------------------------------------------------------------------------------------+
1722
1723+--------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------------+
1724|:warning:`warning:` |nbsp| :diagtext:`non-type template argument referring to` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`with internal linkage is incompatible with C++98`|
1725| ||:diagtext:`function`|| |
1726| |+--------------------+| |
1727| ||:diagtext:`object` || |
1728| |+--------------------+| |
1729+--------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------------+
1730
1731+-----------------------------------------------------------------------------------------------------------------+
1732|:warning:`warning:` |nbsp| :diagtext:`use of 'template' keyword outside of a template is incompatible with C++98`|
1733+-----------------------------------------------------------------------------------------------------------------+
1734
1735+---------------------------------------------------------------------------------------------------------------------+
1736|:warning:`warning:` |nbsp| :diagtext:`default template arguments for a function template are incompatible with C++98`|
1737+---------------------------------------------------------------------------------------------------------------------+
1738
1739+---------------------------+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1740|:warning:`warning:` |nbsp| |+-------------------------------------+| |nbsp| :diagtext:`specialization of` |nbsp| :placeholder:`B` |nbsp| :diagtext:`outside namespace` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is incompatible with C++98`|
1741| ||:diagtext:`class template` || |
1742| |+-------------------------------------+| |
1743| ||:diagtext:`class template partial` || |
1744| |+-------------------------------------+| |
1745| ||:diagtext:`variable template` || |
1746| |+-------------------------------------+| |
1747| ||:diagtext:`variable template partial`|| |
1748| |+-------------------------------------+| |
1749| ||:diagtext:`function template` || |
1750| |+-------------------------------------+| |
1751| ||:diagtext:`member function` || |
1752| |+-------------------------------------+| |
1753| ||:diagtext:`static data member` || |
1754| |+-------------------------------------+| |
1755| ||:diagtext:`member class` || |
1756| |+-------------------------------------+| |
1757| ||:diagtext:`member enumeration` || |
1758| |+-------------------------------------+| |
1759+---------------------------+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1760
1761+----------------------------------------------------------------------------------------+
1762|:warning:`warning:` |nbsp| :diagtext:`trailing return types are incompatible with C++98`|
1763+----------------------------------------------------------------------------------------+
1764
1765+---------------------------------------------------------------------------------------------------------------+
1766|:warning:`warning:` |nbsp| :diagtext:`consecutive right angle brackets are incompatible with C++98 (use '> >')`|
1767+---------------------------------------------------------------------------------------------------------------+
1768
1769+---------------------------------------------------------------------------------------------------------+
1770|:warning:`warning:` |nbsp| :diagtext:`use of 'typename' outside of a template is incompatible with C++98`|
1771+---------------------------------------------------------------------------------------------------------+
1772
1773+-------------------------------------------------------------------------------------------------------+-----------------------+------------------------------------------------+
1774|:warning:`warning:` |nbsp| :diagtext:`befriending` |nbsp| :placeholder:`B` |nbsp| :diagtext:`without '`|+---------------------+|:diagtext:`' keyword is incompatible with C++98`|
1775| ||:diagtext:`struct` || |
1776| |+---------------------+| |
1777| ||:diagtext:`interface`|| |
1778| |+---------------------+| |
1779| ||:diagtext:`union` || |
1780| |+---------------------+| |
1781| ||:diagtext:`class` || |
1782| |+---------------------+| |
1783| ||:diagtext:`enum` || |
1784| |+---------------------+| |
1785+-------------------------------------------------------------------------------------------------------+-----------------------+------------------------------------------------+
1786
1787+-------------------------------------------------------------------------------------------------------+
1788|:warning:`warning:` |nbsp| :diagtext:`using this character in an identifier is incompatible with C++98`|
1789+-------------------------------------------------------------------------------------------------------+
1790
1791+-----------------------------------------------------------------------------------+
1792|:warning:`warning:` |nbsp| :diagtext:`unicode literals are incompatible with C++98`|
1793+-----------------------------------------------------------------------------------+
1794
1795+---------------------------------------------------------------------------------------------------------------+
1796|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' type specifier is incompatible with C++98`|
1797+---------------------------------------------------------------------------------------------------------------+
1798
1799+------------------------------------------------------------------------------------------+
1800|:warning:`warning:` |nbsp| :diagtext:`inheriting constructors are incompatible with C++98`|
1801+------------------------------------------------------------------------------------------+
1802
1803+-------------------------------------------------------------------------------------+
1804|:warning:`warning:` |nbsp| :diagtext:`variadic templates are incompatible with C++98`|
1805+-------------------------------------------------------------------------------------+
1806
1807
1808-Wc++98-compat-bind-to-temporary-copy
1809-------------------------------------
1810**Diagnostic text:**
1811
1812+---------------------------+-----------------------------------------+----------------------------------------------------------------------------------------------------------------------------+------------------------------------------------+----------------------------+
1813|:warning:`warning:` |nbsp| |+---------------------------------------+| |nbsp| :diagtext:`of type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`when binding a reference to a temporary would` |nbsp| |+----------------------------------------------+| |nbsp| :diagtext:`in C++98`|
1814| ||:diagtext:`copying variable` || ||:diagtext:`invoke an inaccessible constructor`|| |
1815| |+---------------------------------------+| |+----------------------------------------------+| |
1816| ||:diagtext:`copying parameter` || ||:diagtext:`find no viable constructor` || |
1817| |+---------------------------------------+| |+----------------------------------------------+| |
1818| ||:diagtext:`returning object` || ||:diagtext:`find ambiguous constructors` || |
1819| |+---------------------------------------+| |+----------------------------------------------+| |
1820| ||:diagtext:`throwing object` || ||:diagtext:`invoke a deleted constructor` || |
1821| |+---------------------------------------+| |+----------------------------------------------+| |
1822| ||:diagtext:`copying member subobject` || | | |
1823| |+---------------------------------------+| | | |
1824| ||:diagtext:`copying array element` || | | |
1825| |+---------------------------------------+| | | |
1826| ||:diagtext:`allocating object` || | | |
1827| |+---------------------------------------+| | | |
1828| ||:diagtext:`copying temporary` || | | |
1829| |+---------------------------------------+| | | |
1830| ||:diagtext:`initializing base subobject`|| | | |
1831| |+---------------------------------------+| | | |
1832| ||:diagtext:`initializing vector element`|| | | |
1833| |+---------------------------------------+| | | |
1834+---------------------------+-----------------------------------------+----------------------------------------------------------------------------------------------------------------------------+------------------------------------------------+----------------------------+
1835
1836
1837-Wc++98-compat-local-type-template-args
1838---------------------------------------
1839**Diagnostic text:**
1840
1841+--------------------------------------------------------------------------------------------------------------------------------------------+
1842|:warning:`warning:` |nbsp| :diagtext:`local type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`as template argument is incompatible with C++98`|
1843+--------------------------------------------------------------------------------------------------------------------------------------------+
1844
1845
1846-Wc++98-compat-pedantic
1847-----------------------
1848Also controls `-Wc++98-compat`_, `-Wc++98-compat-bind-to-temporary-copy`_, `-Wc++98-c++11-compat-pedantic`_, `-Wc++98-c++11-c++14-compat-pedantic`_.
1849
1850**Diagnostic text:**
1851
1852+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------------+
1853|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from array size expression of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| |+-----------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is incompatible with C++98`|
1854| ||:diagtext:`integral` || |
1855| |+-----------------------+| |
1856| ||:diagtext:`enumeration`|| |
1857| |+-----------------------+| |
1858+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------------+
1859
1860+------------------------------------------------------------------------------------------------------------------------+
1861|:warning:`warning:` |nbsp| :diagtext:`cast between pointer-to-function and pointer-to-object is incompatible with C++98`|
1862+------------------------------------------------------------------------------------------------------------------------+
1863
1864+----------------------------------------------------------------------------------------+
1865|:warning:`warning:` |nbsp| :diagtext:`empty macro arguments are incompatible with C++98`|
1866+----------------------------------------------------------------------------------------+
1867
1868+--------------------------------------------------------------------------------------------------------+
1869|:warning:`warning:` |nbsp| :diagtext:`commas at the end of enumerator lists are incompatible with C++98`|
1870+--------------------------------------------------------------------------------------------------------+
1871
1872+-----------------------------------------------------------------------------------+
1873|:warning:`warning:` |nbsp| :diagtext:`extern templates are incompatible with C++98`|
1874+-----------------------------------------------------------------------------------+
1875
1876+-----------------------------------------------------------------------------+
1877|:warning:`warning:` |nbsp| :diagtext:`'long long' is incompatible with C++98`|
1878+-----------------------------------------------------------------------------+
1879
1880+----------------------------------------------------------------------------+
1881|:warning:`warning:` |nbsp| :diagtext:`C++98 requires newline at end of file`|
1882+----------------------------------------------------------------------------+
1883
1884+-------------------------------------------------------------------------------------------------+
1885|:warning:`warning:` |nbsp| :diagtext:`#line number greater than 32767 is incompatible with C++98`|
1886+-------------------------------------------------------------------------------------------------+
1887
1888+-------------------------------------------------------------------------------------------------+
1889|:warning:`warning:` |nbsp| :diagtext:`extra ';' outside of a function is incompatible with C++98`|
1890+-------------------------------------------------------------------------------------------------+
1891
1892+----------------------------------------------------------------------------------+
1893|:warning:`warning:` |nbsp| :diagtext:`variadic macros are incompatible with C++98`|
1894+----------------------------------------------------------------------------------+
1895
1896
1897-Wc++98-compat-unnamed-type-template-args
1898-----------------------------------------
1899**Diagnostic text:**
1900
1901+---------------------------------------------------------------------------------------------------+
1902|:warning:`warning:` |nbsp| :diagtext:`unnamed type as template argument is incompatible with C++98`|
1903+---------------------------------------------------------------------------------------------------+
1904
1905
1906-Wc11-extensions
1907----------------
1908**Diagnostic text:**
1909
1910+---------------------------------------------------------------------------+
1911|:warning:`warning:` |nbsp| :diagtext:`anonymous unions are a C11 extension`|
1912+---------------------------------------------------------------------------+
1913
1914+----------------------------------------------------------------------------------------+
1915|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a C11-specific feature`|
1916+----------------------------------------------------------------------------------------+
1917
1918+----------------------------------------------------------------------------+
1919|:warning:`warning:` |nbsp| :diagtext:`anonymous structs are a C11 extension`|
1920+----------------------------------------------------------------------------+
1921
1922+------------------------------------------------------------------------------------+
1923|:warning:`warning:` |nbsp| :diagtext:`generic selections are a C11-specific feature`|
1924+------------------------------------------------------------------------------------+
1925
1926+--------------------------------------------------------------------------------------+
1927|:warning:`warning:` |nbsp| :diagtext:`\_Noreturn functions are a C11-specific feature`|
1928+--------------------------------------------------------------------------------------+
1929
1930+---------------------------------------------------------------------------------+
1931|:warning:`warning:` |nbsp| :diagtext:`\_Static\_assert is a C11-specific feature`|
1932+---------------------------------------------------------------------------------+
1933
1934
1935-Wc99-compat
1936------------
1937Some of the diagnostics controlled by this flag are enabled by default.
1938
1939**Diagnostic text:**
1940
1941+---------------------------+--------------------------------------------------------+--------------------------------------------+
1942|:warning:`warning:` |nbsp| |+------------------------------------------------------+| |nbsp| :diagtext:`is incompatible with C99`|
1943| ||:diagtext:`using this character in an identifier` || |
1944| |+------------------------------------------------------+| |
1945| ||:diagtext:`starting an identifier with this character`|| |
1946| |+------------------------------------------------------+| |
1947+---------------------------+--------------------------------------------------------+--------------------------------------------+
1948
1949+---------------------------------------------------------------------------------+
1950|:warning:`warning:` |nbsp| :diagtext:`unicode literals are incompatible with C99`|
1951+---------------------------------------------------------------------------------+
1952
1953+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+----------------------------------+
1954|:warning:`warning:` |nbsp| :diagtext:`integer literal is too large to be represented in type 'long', interpreting as 'unsigned long' per C89; this literal will` |nbsp| |+---------------------------------+| |nbsp| :diagtext:`in C99 onwards`|
1955| ||:diagtext:`have type 'long long'`|| |
1956| |+---------------------------------+| |
1957| ||:diagtext:`be ill-formed` || |
1958| |+---------------------------------+| |
1959+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+----------------------------------+
1960
1961
1962-Wc99-extensions
1963----------------
1964Some of the diagnostics controlled by this flag are enabled by default.
1965
1966**Diagnostic text:**
1967
1968+-----------------------------------------------------------------------------------------------+
1969|:warning:`warning:` |nbsp| :diagtext:`initializer for aggregate is not a compile-time constant`|
1970+-----------------------------------------------------------------------------------------------+
1971
1972+---------------------------+----------------------------------+------------------------------+-----------------------+----------------------------+
1973|:warning:`warning:` |nbsp| |+--------------------------------+|:diagtext:`array size` |nbsp| |+---------------------+|:diagtext:`is a C99 feature`|
1974| ||:diagtext:`qualifier in` |nbsp| || || || |
1975| |+--------------------------------+| |+---------------------+| |
1976| ||:diagtext:`static` |nbsp| || || || |
1977| |+--------------------------------+| |+---------------------+| |
1978| || || ||:diagtext:`'\[\*\] '`|| |
1979| |+--------------------------------+| |+---------------------+| |
1980+---------------------------+----------------------------------+------------------------------+-----------------------+----------------------------+
1981
1982+-----------------------------------------------------------------------------------+
1983|:warning:`warning:` |nbsp| :diagtext:`compound literals are a C99-specific feature`|
1984+-----------------------------------------------------------------------------------+
1985
1986+-------------------------------------------------------------------------------+
1987|:warning:`warning:` |nbsp| :diagtext:`flexible array members are a C99 feature`|
1988+-------------------------------------------------------------------------------+
1989
1990+-------------------------------------------------------------------------------------------------+
1991|:warning:`warning:` |nbsp| :diagtext:`variable declaration in for loop is a C99-specific feature`|
1992+-------------------------------------------------------------------------------------------------+
1993
1994+---------------------------------------------------------------------------------------+
1995|:warning:`warning:` |nbsp| :diagtext:`ISO C99 requires whitespace after the macro name`|
1996+---------------------------------------------------------------------------------------+
1997
1998+--------------------------------------------------------------------------------+
1999|:warning:`warning:` |nbsp| :diagtext:`designated initializers are a C99 feature`|
2000+--------------------------------------------------------------------------------+
2001
2002+------------------------------------------------------------------------------+
2003|:warning:`warning:` |nbsp| :diagtext:`empty macro arguments are a C99 feature`|
2004+------------------------------------------------------------------------------+
2005
2006+-------------------------------------------------------------------------------------------------------+
2007|:warning:`warning:` |nbsp| :diagtext:`commas at the end of enumerator lists are a C99-specific feature`|
2008+-------------------------------------------------------------------------------------------------------+
2009
2010+---------------------------------------------------------------------------------------+
2011|:warning:`warning:` |nbsp| :diagtext:`hexadecimal floating constants are a C99 feature`|
2012+---------------------------------------------------------------------------------------+
2013
2014
2015-Wcast-align
2016------------
2017**Diagnostic text:**
2018
2019+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2020|:warning:`warning:` |nbsp| :diagtext:`cast from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`increases required alignment from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D`|
2021+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2022
2023
2024-Wcast-calling-convention
2025-------------------------
2026This diagnostic is enabled by default.
2027
2028**Diagnostic text:**
2029
2030+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2031|:warning:`warning:` |nbsp| :diagtext:`cast between incompatible calling conventions '`:placeholder:`A`:diagtext:`' and '`:placeholder:`B`:diagtext:`'; calls through this pointer may abort at runtime`|
2032+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2033
2034
2035-Wcast-of-sel-type
2036------------------
2037This diagnostic is enabled by default.
2038
2039**Diagnostic text:**
2040
2041+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2042|:warning:`warning:` |nbsp| :diagtext:`cast of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is deprecated; use sel\_getName instead`|
2043+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2044
2045
2046-Wcast-qual
2047-----------
2048**Diagnostic text:**
2049
2050+-------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------+
2051|:warning:`warning:` |nbsp| :diagtext:`cast from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`drops` |nbsp| |+-----------------------------------------+|
2052| ||:diagtext:`const and volatile qualifiers`||
2053| |+-----------------------------------------+|
2054| ||:diagtext:`const qualifier` ||
2055| |+-----------------------------------------+|
2056| ||:diagtext:`volatile qualifier` ||
2057| |+-----------------------------------------+|
2058+-------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------+
2059
2060+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2061|:warning:`warning:` |nbsp| :diagtext:`cast from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`must have all intermediate pointers const qualified to be safe`|
2062+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2063
2064
2065-Wchar-align
2066------------
2067This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
2068
2069-Wchar-subscripts
2070-----------------
2071**Diagnostic text:**
2072
2073+------------------------------------------------------------+-------------------------+-------------------------------------+
2074|:warning:`warning:` |nbsp| :diagtext:`array section` |nbsp| |+-----------------------+| |nbsp| :diagtext:`is of type 'char'`|
2075| ||:diagtext:`lower bound`|| |
2076| |+-----------------------+| |
2077| ||:diagtext:`length` || |
2078| |+-----------------------+| |
2079+------------------------------------------------------------+-------------------------+-------------------------------------+
2080
2081+------------------------------------------------------------------------+
2082|:warning:`warning:` |nbsp| :diagtext:`array subscript is of type 'char'`|
2083+------------------------------------------------------------------------+
2084
2085
2086-Wclang-cl-pch
2087--------------
2088This diagnostic is enabled by default.
2089
2090**Diagnostic text:**
2091
2092+-------------------------------------------------------------------------------------------------------------------------+
2093|:warning:`warning:` |nbsp| :diagtext:`support for '/Yc' with more than one source file not implemented yet; flag ignored`|
2094+-------------------------------------------------------------------------------------------------------------------------+
2095
2096+------------------------------------------------------------------------------------------------------------------------------+
2097|:warning:`warning:` |nbsp| :diagtext:`support for '/Yc' and '/Yu' with different filenames not implemented yet; flags ignored`|
2098+------------------------------------------------------------------------------------------------------------------------------+
2099
2100+--------------------------------------------------------------------------------------------------------------------------------------+
2101|:warning:`warning:` |nbsp| :diagtext:`support for '`:placeholder:`A`:diagtext:`' without a filename not implemented yet; flag ignored`|
2102+--------------------------------------------------------------------------------------------------------------------------------------+
2103
2104+----------------------------------------------------------------------------------------------------------------------------------------------------+
2105|:warning:`warning:` |nbsp| :diagtext:`support for '`:placeholder:`A`:diagtext:`' without a corresponding /FI flag not implemented yet; flag ignored`|
2106+----------------------------------------------------------------------------------------------------------------------------------------------------+
2107
2108
2109-Wclass-varargs
2110---------------
2111Some of the diagnostics controlled by this flag are enabled by default.
2112
2113Also controls `-Wnon-pod-varargs`_.
2114
2115**Diagnostic text:**
2116
2117+---------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------+
2118|:warning:`warning:` |nbsp| :diagtext:`passing object of class type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`through variadic` |nbsp| |+-----------------------+|+--------------------------------------------------------------------+|
2119| ||:diagtext:`function` ||| ||
2120| |+-----------------------+|+--------------------------------------------------------------------+|
2121| ||:diagtext:`block` |||+------------------------------------------------------------------+||
2122| |+-----------------------+|||:diagtext:`; did you mean to call '`:placeholder:`D`:diagtext:`'?`|||
2123| ||:diagtext:`method` |||+------------------------------------------------------------------+||
2124| |+-----------------------+|+--------------------------------------------------------------------+|
2125| ||:diagtext:`constructor`|| |
2126| |+-----------------------+| |
2127+---------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------+
2128
2129
2130-Wcomma
2131-------
2132**Diagnostic text:**
2133
2134+-----------------------------------------------------------------------------+
2135|:warning:`warning:` |nbsp| :diagtext:`possible misuse of comma operator here`|
2136+-----------------------------------------------------------------------------+
2137
2138
2139-Wcomment
2140---------
2141Some of the diagnostics controlled by this flag are enabled by default.
2142
2143**Diagnostic text:**
2144
2145+--------------------------------------------------------------------------------------------------+
2146|:warning:`warning:` |nbsp| :diagtext:`escaped newline between \*/ characters at block comment end`|
2147+--------------------------------------------------------------------------------------------------+
2148
2149+-----------------------------------------------------------------------------------+
2150|:warning:`warning:` |nbsp| :diagtext:`// comments are not allowed in this language`|
2151+-----------------------------------------------------------------------------------+
2152
2153+------------------------------------------------------------+
2154|:warning:`warning:` |nbsp| :diagtext:`multi-line // comment`|
2155+------------------------------------------------------------+
2156
2157+-----------------------------------------------------------------+
2158|:warning:`warning:` |nbsp| :diagtext:`'/\*' within block comment`|
2159+-----------------------------------------------------------------+
2160
2161
2162-Wcomments
2163----------
2164Synonym for `-Wcomment`_.
2165
2166
2167-Wcompare-distinct-pointer-types
2168--------------------------------
2169This diagnostic is enabled by default.
2170
2171**Diagnostic text:**
2172
2173+---------------------------------------------------------------------------+
2174|:warning:`warning:` |nbsp| :diagtext:`comparison of distinct pointer types`|
2175+---------------------------------------------------------------------------+
2176
2177+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2178|:warning:`warning:` |nbsp| :diagtext:`comparison of distinct pointer types (`:placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`:diagtext:`) uses non-standard composite pointer type` |nbsp| :placeholder:`C`|
2179+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2180
2181
2182-Wcomplex-component-init
2183------------------------
2184**Diagnostic text:**
2185
2186+----------------------------------------------------------------------------------------------------------------------+
2187|:warning:`warning:` |nbsp| :diagtext:`complex initialization specifying real and imaginary components is an extension`|
2188+----------------------------------------------------------------------------------------------------------------------+
2189
2190
2191-Wconditional-type-mismatch
2192---------------------------
2193This diagnostic is enabled by default.
2194
2195**Diagnostic text:**
2196
2197+----------------------------------------------------------------------------------------------+
2198|:warning:`warning:` |nbsp| :diagtext:`pointer/integer type mismatch in conditional expression`|
2199+----------------------------------------------------------------------------------------------+
2200
2201
2202-Wconditional-uninitialized
2203---------------------------
2204**Diagnostic text:**
2205
2206+----------------------------------------------------------------------------------------------------------------------------+-------------------------------+
2207|:warning:`warning:` |nbsp| :diagtext:`variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may be uninitialized when` |nbsp| |+-----------------------------+|
2208| ||:diagtext:`used here` ||
2209| |+-----------------------------+|
2210| ||:diagtext:`captured by block`||
2211| |+-----------------------------+|
2212+----------------------------------------------------------------------------------------------------------------------------+-------------------------------+
2213
2214
2215-Wconfig-macros
2216---------------
2217This diagnostic is enabled by default.
2218
2219**Diagnostic text:**
2220
2221+---------------------------+------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+---------------------------------------------------------+
2222|:warning:`warning:` |nbsp| |+----------------------+| |nbsp| :diagtext:`of configuration macro '`:placeholder:`B`:diagtext:`' has no effect on the import of '`:placeholder:`C`:diagtext:`'; pass '`|+------------------------------------------------+|:diagtext:`' on the command line to configure the module`|
2223| ||:diagtext:`definition`|| ||+----------------------------------------------+|| |
2224| |+----------------------+| |||:diagtext:`-D`:placeholder:`B`:diagtext:`=...`||| |
2225| ||:diagtext:`#undef` || ||+----------------------------------------------+|| |
2226| |+----------------------+| |+------------------------------------------------+| |
2227| | | ||+------------------------------+ || |
2228| | | |||:diagtext:`-U`:placeholder:`B`| || |
2229| | | ||+------------------------------+ || |
2230| | | |+------------------------------------------------+| |
2231+---------------------------+------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------+---------------------------------------------------------+
2232
2233
2234-Wconstant-conversion
2235---------------------
2236This diagnostic is enabled by default.
2237
2238Also controls `-Wbitfield-constant-conversion`_.
2239
2240**Diagnostic text:**
2241
2242+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2243|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D` |nbsp| :diagtext:`changes value from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
2244+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2245
2246
2247-Wconstant-logical-operand
2248--------------------------
2249This diagnostic is enabled by default.
2250
2251**Diagnostic text:**
2252
2253+----------------------------------------------------------------------------------------------------------+
2254|:warning:`warning:` |nbsp| :diagtext:`use of logical '`:placeholder:`A`:diagtext:`' with constant operand`|
2255+----------------------------------------------------------------------------------------------------------+
2256
2257
2258-Wconstexpr-not-const
2259---------------------
2260This diagnostic is enabled by default.
2261
2262**Diagnostic text:**
2263
2264+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2265|:warning:`warning:` |nbsp| :diagtext:`'constexpr' non-static member function will not be implicitly 'const' in C++14; add 'const' to avoid a change in behavior`|
2266+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2267
2268
2269-Wconsumed
2270----------
2271**Diagnostic text:**
2272
2273+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2274|:warning:`warning:` |nbsp| :diagtext:`consumed analysis attribute is attached to member of class '`:placeholder:`A`:diagtext:`' which isn't marked as consumable`|
2275+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2276
2277+--------------------------------------------------------------------------------------------------------------------------------+
2278|:warning:`warning:` |nbsp| :diagtext:`state of variable '`:placeholder:`A`:diagtext:`' must match at the entry and exit of loop`|
2279+--------------------------------------------------------------------------------------------------------------------------------+
2280
2281+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2282|:warning:`warning:` |nbsp| :diagtext:`parameter '`:placeholder:`A`:diagtext:`' not in expected state when the function returns: expected '`:placeholder:`B`:diagtext:`', observed '`:placeholder:`C`:diagtext:`'`|
2283+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2284
2285+-------------------------------------------------------------------------------------------------------------------------------------------------------+
2286|:warning:`warning:` |nbsp| :diagtext:`argument not in expected state; expected '`:placeholder:`A`:diagtext:`', observed '`:placeholder:`B`:diagtext:`'`|
2287+-------------------------------------------------------------------------------------------------------------------------------------------------------+
2288
2289+---------------------------------------------------------------------------------------------------------------+
2290|:warning:`warning:` |nbsp| :diagtext:`return state set for an unconsumable type '`:placeholder:`A`:diagtext:`'`|
2291+---------------------------------------------------------------------------------------------------------------+
2292
2293+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
2294|:warning:`warning:` |nbsp| :diagtext:`return value not in expected state; expected '`:placeholder:`A`:diagtext:`', observed '`:placeholder:`B`:diagtext:`'`|
2295+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
2296
2297+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2298|:warning:`warning:` |nbsp| :diagtext:`invalid invocation of method '`:placeholder:`A`:diagtext:`' on object '`:placeholder:`B`:diagtext:`' while it is in the '`:placeholder:`C`:diagtext:`' state`|
2299+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2300
2301+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2302|:warning:`warning:` |nbsp| :diagtext:`invalid invocation of method '`:placeholder:`A`:diagtext:`' on a temporary object while it is in the '`:placeholder:`B`:diagtext:`' state`|
2303+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2304
2305
2306-Wconversion
2307------------
2308Some of the diagnostics controlled by this flag are enabled by default.
2309
2310Also controls `-Wbool-conversion`_, `-Wconstant-conversion`_, `-Wenum-conversion`_, `-Wfloat-conversion`_, `-Wshorten-64-to-32`_, `-Wint-conversion`_, `-Wliteral-conversion`_, `-Wnon-literal-null-conversion`_, `-Wnull-conversion`_, `-Wobjc-literal-conversion`_, `-Wsign-conversion`_, `-Wstring-conversion`_.
2311
2312**Diagnostic text:**
2313
2314+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
2315|:warning:`warning:` |nbsp| :diagtext:`implicit conversion discards imaginary component:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
2316+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
2317
2318+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2319|:warning:`warning:` |nbsp| :diagtext:`implicit conversion loses floating-point precision:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
2320+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
2321
2322+---------------------------------------------------------------------------------------------------------------------------------------------------------+
2323|:warning:`warning:` |nbsp| :diagtext:`implicit conversion loses integer precision:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
2324+---------------------------------------------------------------------------------------------------------------------------------------------------------+
2325
2326+--------------------------------------------------------------------------------------------------------------------------------------------------------+
2327|:warning:`warning:` |nbsp| :diagtext:`implicit conversion turns vector to scalar:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
2328+--------------------------------------------------------------------------------------------------------------------------------------------------------+
2329
2330+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2331|:warning:`warning:` |nbsp| :diagtext:`non-type template argument with value '`:placeholder:`A`:diagtext:`' converted to '`:placeholder:`B`:diagtext:`' for unsigned template parameter of type` |nbsp| :placeholder:`C`|
2332+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2333
2334+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2335|:warning:`warning:` |nbsp| :diagtext:`non-type template argument value '`:placeholder:`A`:diagtext:`' truncated to '`:placeholder:`B`:diagtext:`' for template parameter of type` |nbsp| :placeholder:`C`|
2336+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2337
2338
2339-Wconversion-null
2340-----------------
2341Synonym for `-Wnull-conversion`_.
2342
2343
2344-Wcoreturn-without-coawait
2345--------------------------
2346This diagnostic is enabled by default.
2347
2348**Diagnostic text:**
2349
2350+--------------------------------------------------------------------------------------------------------------------+
2351|:warning:`warning:` |nbsp| :diagtext:`'co\_return' used in a function that uses neither 'co\_await' nor 'co\_yield'`|
2352+--------------------------------------------------------------------------------------------------------------------+
2353
2354
2355-Wcovered-switch-default
2356------------------------
2357**Diagnostic text:**
2358
2359+--------------------------------------------------------------------------------------------------+
2360|:warning:`warning:` |nbsp| :diagtext:`default label in switch which covers all enumeration values`|
2361+--------------------------------------------------------------------------------------------------+
2362
2363
2364-Wcstring-format-directive
2365--------------------------
2366**Diagnostic text:**
2367
2368+------------------------------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------------+------------------------+
2369|:warning:`warning:` |nbsp| :diagtext:`using` |nbsp| :placeholder:`A` |nbsp| :diagtext:`directive in` |nbsp| |+--------------------+| |nbsp| :diagtext:`which is being passed as a formatting argument to the formatting` |nbsp| |+----------------------+|
2370| ||:diagtext:`NSString`|| ||:diagtext:`method` ||
2371| |+--------------------+| |+----------------------+|
2372| ||:diagtext:`CFString`|| ||:diagtext:`CFfunction`||
2373| |+--------------------+| |+----------------------+|
2374+------------------------------------------------------------------------------------------------------------+----------------------+--------------------------------------------------------------------------------------------+------------------------+
2375
2376
2377-Wctor-dtor-privacy
2378-------------------
2379This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
2380
2381-Wcuda-compat
2382-------------
2383Some of the diagnostics controlled by this flag are enabled by default.
2384
2385**Diagnostic text:**
2386
2387+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
2388|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute parameter` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is negative and will be ignored`|
2389+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
2390
2391+------------------------------------------------------------------------------------------------------------+
2392|:warning:`warning:` |nbsp| :diagtext:`ignored 'inline' attribute on kernel function` |nbsp| :placeholder:`A`|
2393+------------------------------------------------------------------------------------------------------------+
2394
2395+--------------------------------------------------------------------------------------------------------------------------------------------------------+
2396|:warning:`warning:` |nbsp| :diagtext:`kernel function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a member function; this may not be accepted by nvcc`|
2397+--------------------------------------------------------------------------------------------------------------------------------------------------------+
2398
2399+--------------------------------------------------------------------------------------------------------------+
2400|:warning:`warning:` |nbsp| :diagtext:`argument to '#pragma unroll' should not be in parentheses in CUDA C/C++`|
2401+--------------------------------------------------------------------------------------------------------------+
2402
2403
2404-Wcustom-atomic-properties
2405--------------------------
2406**Diagnostic text:**
2407
2408+---------------------------------------------------------------------------------------------------------------------------------------+--------------------+----------------------------------------------------------------------------+
2409|:warning:`warning:` |nbsp| :diagtext:`atomic by default property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has a user defined` |nbsp| |+------------------+| |nbsp| :diagtext:`(property should be marked 'atomic' if this is intended)`|
2410| ||:diagtext:`getter`|| |
2411| |+------------------+| |
2412| ||:diagtext:`setter`|| |
2413| |+------------------+| |
2414+---------------------------------------------------------------------------------------------------------------------------------------+--------------------+----------------------------------------------------------------------------+
2415
2416
2417-Wdangling-else
2418---------------
2419This diagnostic is enabled by default.
2420
2421**Diagnostic text:**
2422
2423+---------------------------------------------------------------------------------+
2424|:warning:`warning:` |nbsp| :diagtext:`add explicit braces to avoid dangling else`|
2425+---------------------------------------------------------------------------------+
2426
2427
2428-Wdangling-field
2429----------------
2430This diagnostic is enabled by default.
2431
2432**Diagnostic text:**
2433
2434+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
2435|:warning:`warning:` |nbsp| :diagtext:`binding reference member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to stack allocated parameter` |nbsp| :placeholder:`B`|
2436+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
2437
2438+----------------------------------------------------------------+----------------------------------+----------------------------------------------------------------------------------+
2439|:warning:`warning:` |nbsp| :diagtext:`binding reference` |nbsp| |+--------------------------------+|:diagtext:`member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to a temporary value`|
2440| || || |
2441| |+--------------------------------+| |
2442| ||:diagtext:`subobject of` |nbsp| || |
2443| |+--------------------------------+| |
2444+----------------------------------------------------------------+----------------------------------+----------------------------------------------------------------------------------+
2445
2446+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2447|:warning:`warning:` |nbsp| :diagtext:`initializing pointer member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with the stack address of parameter` |nbsp| :placeholder:`B`|
2448+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2449
2450
2451-Wdangling-initializer-list
2452---------------------------
2453This diagnostic is enabled by default.
2454
2455**Diagnostic text:**
2456
2457+-----------------------------------------------------------------------------------------------------------------+---------------------------------+
2458|:warning:`warning:` |nbsp| :diagtext:`array backing the initializer list will be destroyed at the end of` |nbsp| |+-------------------------------+|
2459| ||:diagtext:`the full-expression`||
2460| |+-------------------------------+|
2461| ||:diagtext:`the constructor` ||
2462| |+-------------------------------+|
2463+-----------------------------------------------------------------------------------------------------------------+---------------------------------+
2464
2465
2466-Wdate-time
2467-----------
2468**Diagnostic text:**
2469
2470+------------------------------------------------------------------------------------------+
2471|:warning:`warning:` |nbsp| :diagtext:`expansion of date or time macro is not reproducible`|
2472+------------------------------------------------------------------------------------------+
2473
2474
2475-Wdealloc-in-category
2476---------------------
2477This diagnostic is enabled by default.
2478
2479**Diagnostic text:**
2480
2481+---------------------------------------------------------------------------------+
2482|:warning:`warning:` |nbsp| :diagtext:`-dealloc is being overridden in a category`|
2483+---------------------------------------------------------------------------------+
2484
2485
2486-Wdebug-compression-unavailable
2487-------------------------------
2488This diagnostic is enabled by default.
2489
2490**Diagnostic text:**
2491
2492+------------------------------------------------------------------------------------------+
2493|:warning:`warning:` |nbsp| :diagtext:`cannot compress debug sections (zlib not installed)`|
2494+------------------------------------------------------------------------------------------+
2495
2496
2497-Wdeclaration-after-statement
2498-----------------------------
2499**Diagnostic text:**
2500
2501+-----------------------------------------------------------------------------------+
2502|:warning:`warning:` |nbsp| :diagtext:`ISO C90 forbids mixing declarations and code`|
2503+-----------------------------------------------------------------------------------+
2504
2505
2506-Wdelegating-ctor-cycles
2507------------------------
2508This diagnostic is an error by default, but the flag ``-Wno-delegating-ctor-cycles`` can be used to disable the error.
2509
2510**Diagnostic text:**
2511
2512+------------------------------------------------------------------------------------------------------------------------+
2513|:error:`error:` |nbsp| :diagtext:`constructor for` |nbsp| :placeholder:`A` |nbsp| :diagtext:`creates a delegation cycle`|
2514+------------------------------------------------------------------------------------------------------------------------+
2515
2516
2517-Wdelete-incomplete
2518-------------------
2519This diagnostic is enabled by default.
2520
2521**Diagnostic text:**
2522
2523+-------------------------------------------------------------------------------------------------------------------+
2524|:warning:`warning:` |nbsp| :diagtext:`cannot delete expression with pointer-to-'void' type` |nbsp| :placeholder:`A`|
2525+-------------------------------------------------------------------------------------------------------------------+
2526
2527+--------------------------------------------------------------------------------------------------------------------------------------------------+
2528|:warning:`warning:` |nbsp| :diagtext:`deleting pointer to incomplete type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may cause undefined behavior`|
2529+--------------------------------------------------------------------------------------------------------------------------------------------------+
2530
2531
2532-Wdelete-non-virtual-dtor
2533-------------------------
2534Some of the diagnostics controlled by this flag are enabled by default.
2535
2536**Diagnostic text:**
2537
2538+---------------------------+------------------------+------------------------------------------------------------------------------------------------------------------------+
2539|:warning:`warning:` |nbsp| |+----------------------+| |nbsp| :diagtext:`called on` |nbsp| :placeholder:`B` |nbsp| :diagtext:`that is abstract but has non-virtual destructor`|
2540| ||:diagtext:`delete` || |
2541| |+----------------------+| |
2542| ||:diagtext:`destructor`|| |
2543| |+----------------------+| |
2544+---------------------------+------------------------+------------------------------------------------------------------------------------------------------------------------+
2545
2546+---------------------------+------------------------+----------------------------------------------------------------------------------------------------------------------------------------+
2547|:warning:`warning:` |nbsp| |+----------------------+| |nbsp| :diagtext:`called on non-final` |nbsp| :placeholder:`B` |nbsp| :diagtext:`that has virtual functions but non-virtual destructor`|
2548| ||:diagtext:`delete` || |
2549| |+----------------------+| |
2550| ||:diagtext:`destructor`|| |
2551| |+----------------------+| |
2552+---------------------------+------------------------+----------------------------------------------------------------------------------------------------------------------------------------+
2553
2554
2555-Wdeprecated
2556------------
2557Some of the diagnostics controlled by this flag are enabled by default.
2558
2559Also controls `-Wdeprecated-attributes`_, `-Wdeprecated-declarations`_, `-Wdeprecated-increment-bool`_, `-Wdeprecated-register`_, `-Wdeprecated-writable-strings`_.
2560
2561**Diagnostic text:**
2562
2563+---------------------------------------------------------------+
2564|:warning:`warning:` |nbsp| :diagtext:`-O4 is equivalent to -O3`|
2565+---------------------------------------------------------------+
2566
2567+---------------------------------------------------------------------------------------------------------+
2568|:warning:`warning:` |nbsp| :diagtext:`access declarations are deprecated; use using declarations instead`|
2569+---------------------------------------------------------------------------------------------------------+
2570
2571+--------------------------------------------------------------------------+---------------------------------+-----------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------+
2572|:warning:`warning:` |nbsp| :diagtext:`definition of implicit copy` |nbsp| |+-------------------------------+| |nbsp| :diagtext:`for` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is deprecated because it has a user-declared` |nbsp| |+------------------------------------------------------------+|
2573| ||:diagtext:`constructor` || ||+------------------------+---------------------------------+||
2574| |+-------------------------------+| |||:diagtext:`copy` |nbsp| |+-------------------------------+|||
2575| ||:diagtext:`assignment operator`|| ||| ||:diagtext:`assignment operator`||||
2576| |+-------------------------------+| ||| |+-------------------------------+|||
2577| | | ||| ||:diagtext:`constructor` ||||
2578| | | ||| |+-------------------------------+|||
2579| | | ||+------------------------+---------------------------------+||
2580| | | |+------------------------------------------------------------+|
2581| | | ||:diagtext:`destructor` ||
2582| | | |+------------------------------------------------------------+|
2583+--------------------------------------------------------------------------+---------------------------------+-----------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------+
2584
2585+-------------------------------------------------------------------------------------------------------------------------------------+
2586|:warning:`warning:` |nbsp| :diagtext:`out-of-line definition of constexpr static data member is redundant in C++17 and is deprecated`|
2587+-------------------------------------------------------------------------------------------------------------------------------------+
2588
2589+----------------------------------------------------------------------------------------------------------------------------------------+
2590|:warning:`warning:` |nbsp| :diagtext:`argument '`:placeholder:`A`:diagtext:`' is deprecated, use '`:placeholder:`B`:diagtext:`' instead`|
2591+----------------------------------------------------------------------------------------------------------------------------------------+
2592
2593+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2594|:warning:`warning:` |nbsp| :diagtext:`treating '`:placeholder:`A`:diagtext:`' input as '`:placeholder:`B`:diagtext:`' when in C++ mode, this behavior is deprecated`|
2595+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2596
2597+--------------------------------------------------------------------------------------+
2598|:warning:`warning:` |nbsp| :diagtext:`dynamic exception specifications are deprecated`|
2599+--------------------------------------------------------------------------------------+
2600
2601+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
2602|:warning:`warning:` |nbsp| :diagtext:`OpenCL version` |nbsp| :placeholder:`A` |nbsp| :diagtext:`does not support the option '`:placeholder:`B`:diagtext:`'`|
2603+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
2604
2605+------------------------------------------------------------------------------------+
2606|:warning:`warning:` |nbsp| :diagtext:`Use of 'long' with '\_\_vector' is deprecated`|
2607+------------------------------------------------------------------------------------+
2608
2609
2610-Wdeprecated-attributes
2611-----------------------
2612This diagnostic is enabled by default.
2613
2614**Diagnostic text:**
2615
2616+------------------------------------------------------------------------------------------------------------------------------------------------+
2617|:warning:`warning:` |nbsp| :diagtext:`specifying vector types with the 'mode' attribute is deprecated; use the 'vector\_size' attribute instead`|
2618+------------------------------------------------------------------------------------------------------------------------------------------------+
2619
2620
2621-Wdeprecated-declarations
2622-------------------------
2623This diagnostic is enabled by default.
2624
2625**Diagnostic text:**
2626
2627+-----------------------------------------------------------------------------------------------------------------+
2628|:warning:`warning:` |nbsp| :diagtext:`use of C-style parameters in Objective-C method declarations is deprecated`|
2629+-----------------------------------------------------------------------------------------------------------------+
2630
2631+----------------------------------------------------------------------------+
2632|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is deprecated`|
2633+----------------------------------------------------------------------------+
2634
2635+---------------------------------------------------------------------------------------------------------------------+
2636|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may be deprecated because the receiver type is unknown`|
2637+---------------------------------------------------------------------------------------------------------------------+
2638
2639+-----------------------------------------------------------------------------------------------------+
2640|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is deprecated:` |nbsp| :placeholder:`B`|
2641+-----------------------------------------------------------------------------------------------------+
2642
2643+-------------------------------------------------------------------------------------------------------------------------------------+
2644|:warning:`warning:` |nbsp| :diagtext:`property access is using` |nbsp| :placeholder:`A` |nbsp| :diagtext:`method which is deprecated`|
2645+-------------------------------------------------------------------------------------------------------------------------------------+
2646
2647
2648-Wdeprecated-implementations
2649----------------------------
2650**Diagnostic text:**
2651
2652+----------------------------------------------------------------------+----------------------+
2653|:warning:`warning:` |nbsp| :diagtext:`Implementing deprecated` |nbsp| |+--------------------+|
2654| ||:diagtext:`method` ||
2655| |+--------------------+|
2656| ||:diagtext:`class` ||
2657| |+--------------------+|
2658| ||:diagtext:`category`||
2659| |+--------------------+|
2660+----------------------------------------------------------------------+----------------------+
2661
2662
2663-Wdeprecated-increment-bool
2664---------------------------
2665This diagnostic is enabled by default.
2666
2667**Diagnostic text:**
2668
2669+---------------------------------------------------------------------------------------------------------------------+
2670|:warning:`warning:` |nbsp| :diagtext:`incrementing expression of type bool is deprecated and incompatible with C++1z`|
2671+---------------------------------------------------------------------------------------------------------------------+
2672
2673
2674-Wdeprecated-objc-isa-usage
2675---------------------------
2676This diagnostic is enabled by default.
2677
2678**Diagnostic text:**
2679
2680+-------------------------------------------------------------------------------------------------------------------+
2681|:warning:`warning:` |nbsp| :diagtext:`assignment to Objective-C's isa is deprecated in favor of object\_setClass()`|
2682+-------------------------------------------------------------------------------------------------------------------+
2683
2684+----------------------------------------------------------------------------------------------------------------------+
2685|:warning:`warning:` |nbsp| :diagtext:`direct access to Objective-C's isa is deprecated in favor of object\_getClass()`|
2686+----------------------------------------------------------------------------------------------------------------------+
2687
2688
2689-Wdeprecated-objc-pointer-introspection
2690---------------------------------------
2691This diagnostic is enabled by default.
2692
2693Also controls `-Wdeprecated-objc-pointer-introspection-performSelector`_.
2694
2695**Diagnostic text:**
2696
2697+--------------------------------------------------------------------------------------------------------------------------+
2698|:warning:`warning:` |nbsp| :diagtext:`bitmasking for introspection of Objective-C object pointers is strongly discouraged`|
2699+--------------------------------------------------------------------------------------------------------------------------+
2700
2701
2702-Wdeprecated-objc-pointer-introspection-performSelector
2703-------------------------------------------------------
2704This diagnostic is enabled by default.
2705
2706**Diagnostic text:**
2707
2708+--------------------------------------------------------------------------------------------------------------------------+
2709|:warning:`warning:` |nbsp| :diagtext:`bitmasking for introspection of Objective-C object pointers is strongly discouraged`|
2710+--------------------------------------------------------------------------------------------------------------------------+
2711
2712
2713-Wdeprecated-register
2714---------------------
2715This diagnostic is enabled by default.
2716
2717**Diagnostic text:**
2718
2719+-------------------------------------------------------------------------------------------------------------------+
2720|:warning:`warning:` |nbsp| :diagtext:`'register' storage class specifier is deprecated and incompatible with C++1z`|
2721+-------------------------------------------------------------------------------------------------------------------+
2722
2723
2724-Wdeprecated-writable-strings
2725-----------------------------
2726Synonym for `-Wc++11-compat-deprecated-writable-strings`_.
2727
2728
2729-Wdirect-ivar-access
2730--------------------
2731**Diagnostic text:**
2732
2733+------------------------------------------------------------------------------------------------------------------------------+
2734|:warning:`warning:` |nbsp| :diagtext:`instance variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is being directly accessed`|
2735+------------------------------------------------------------------------------------------------------------------------------+
2736
2737
2738-Wdisabled-macro-expansion
2739--------------------------
2740**Diagnostic text:**
2741
2742+----------------------------------------------------------------------------+
2743|:warning:`warning:` |nbsp| :diagtext:`disabled expansion of recursive macro`|
2744+----------------------------------------------------------------------------+
2745
2746
2747-Wdisabled-optimization
2748-----------------------
2749This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
2750
2751-Wdiscard-qual
2752--------------
2753This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
2754
2755-Wdistributed-object-modifiers
2756------------------------------
2757This diagnostic is enabled by default.
2758
2759**Diagnostic text:**
2760
2761+----------------------------------------------------------------------------------------------------------------------------------------------+
2762|:warning:`warning:` |nbsp| :diagtext:`conflicting distributed object modifiers on parameter type in implementation of` |nbsp| :placeholder:`A`|
2763+----------------------------------------------------------------------------------------------------------------------------------------------+
2764
2765+-------------------------------------------------------------------------------------------------------------------------------------------+
2766|:warning:`warning:` |nbsp| :diagtext:`conflicting distributed object modifiers on return type in implementation of` |nbsp| :placeholder:`A`|
2767+-------------------------------------------------------------------------------------------------------------------------------------------+
2768
2769
2770-Wdiv-by-zero
2771-------------
Richard Smithce9d5862016-09-14 01:51:10 +00002772Synonym for `-Wdivision-by-zero`_.
2773
Richard Smithb6a3b4b2016-09-12 05:58:29 +00002774
2775-Wdivision-by-zero
2776------------------
2777This diagnostic is enabled by default.
2778
2779**Diagnostic text:**
2780
2781+---------------------------+-----------------------+----------------------------------------+
2782|:warning:`warning:` |nbsp| |+---------------------+| |nbsp| :diagtext:`by zero is undefined`|
2783| ||:diagtext:`remainder`|| |
2784| |+---------------------+| |
2785| ||:diagtext:`division` || |
2786| |+---------------------+| |
2787+---------------------------+-----------------------+----------------------------------------+
2788
2789
2790-Wdll-attribute-on-redeclaration
2791--------------------------------
2792This diagnostic is enabled by default.
2793
2794**Diagnostic text:**
2795
2796+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2797|:warning:`warning:` |nbsp| :diagtext:`redeclaration of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`should not add` |nbsp| :placeholder:`B` |nbsp| :diagtext:`attribute`|
2798+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
2799
2800
2801-Wdllexport-explicit-instantiation-decl
2802---------------------------------------
2803This diagnostic is enabled by default.
2804
2805**Diagnostic text:**
2806
2807+---------------------------------------------------------------------------------------------------+
2808|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation declaration should not be 'dllexport'`|
2809+---------------------------------------------------------------------------------------------------+
2810
2811
2812-Wdllimport-static-field-def
2813----------------------------
2814This diagnostic is enabled by default.
2815
2816**Diagnostic text:**
2817
2818+---------------------------------------------------------------------------+
2819|:warning:`warning:` |nbsp| :diagtext:`definition of dllimport static field`|
2820+---------------------------------------------------------------------------+
2821
2822
2823-Wdocumentation
2824---------------
2825Also controls `-Wdocumentation-html`_, `-Wdocumentation-deprecated-sync`_.
2826
2827**Diagnostic text:**
2828
2829+----------------------------------------+----------------+-----------------------+------------------------------------------------------------------------+-----------------------+-------------------------------+
2830|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|+---------------------+|:diagtext:`' command should not be used in a comment attached to a non-`|+---------------------+| |nbsp| :diagtext:`declaration`|
2831| ||:diagtext:`\\`|||:diagtext:`class` || ||:diagtext:`class` || |
2832| |+--------------+|+---------------------+| |+---------------------+| |
2833| ||:diagtext:`@` |||:diagtext:`interface`|| ||:diagtext:`interface`|| |
2834| |+--------------+|+---------------------+| |+---------------------+| |
2835| | ||:diagtext:`protocol` || ||:diagtext:`protocol` || |
2836| | |+---------------------+| |+---------------------+| |
2837| | ||:diagtext:`struct` || ||:diagtext:`struct` || |
2838| | |+---------------------+| |+---------------------+| |
2839| | ||:diagtext:`union` || ||:diagtext:`union` || |
2840| | |+---------------------+| |+---------------------+| |
2841+----------------------------------------+----------------+-----------------------+------------------------------------------------------------------------+-----------------------+-------------------------------+
2842
2843+-----------------------------------------------------------+----------------+-----------------------------+
2844|:warning:`warning:` |nbsp| :diagtext:`duplicated command '`|+--------------+|:placeholder:`B`:diagtext:`'`|
2845| ||:diagtext:`\\`|| |
2846| |+--------------+| |
2847| ||:diagtext:`@` || |
2848| |+--------------+| |
2849+-----------------------------------------------------------+----------------+-----------------------------+
2850
2851+------------------------------------------------------------------+----------------+-------------------------------------+
2852|:warning:`warning:` |nbsp| :diagtext:`empty paragraph passed to '`|+--------------+|:placeholder:`B`:diagtext:`' command`|
2853| ||:diagtext:`\\`|| |
2854| |+--------------+| |
2855| ||:diagtext:`@` || |
2856| |+--------------+| |
2857+------------------------------------------------------------------+----------------+-------------------------------------+
2858
2859+----------------------------------------+----------------+--------------------------+---------------------------------------------------------------------------------------------+
2860|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|+------------------------+|:diagtext:`' command should not be used in a comment attached to a non-container declaration`|
2861| ||:diagtext:`\\`|||:diagtext:`classdesign` || |
2862| |+--------------+|+------------------------+| |
2863| ||:diagtext:`@` |||:diagtext:`coclass` || |
2864| |+--------------+|+------------------------+| |
2865| | ||:diagtext:`dependency` || |
2866| | |+------------------------+| |
2867| | ||:diagtext:`helper` || |
2868| | |+------------------------+| |
2869| | ||:diagtext:`helperclass` || |
2870| | |+------------------------+| |
2871| | ||:diagtext:`helps` || |
2872| | |+------------------------+| |
2873| | ||:diagtext:`instancesize`|| |
2874| | |+------------------------+| |
2875| | ||:diagtext:`ownership` || |
2876| | |+------------------------+| |
2877| | ||:diagtext:`performance` || |
2878| | |+------------------------+| |
2879| | ||:diagtext:`security` || |
2880| | |+------------------------+| |
2881| | ||:diagtext:`superclass` || |
2882| | |+------------------------+| |
2883+----------------------------------------+----------------+--------------------------+---------------------------------------------------------------------------------------------+
2884
2885+----------------------------------------+----------------+---------------------------+---------------------------------------------------------------------+-----------------------------------+-------------------------------+
2886|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|+-------------------------+|:diagtext:`' command should be used in a comment attached to` |nbsp| |+---------------------------------+| |nbsp| :diagtext:`declaration`|
2887| ||:diagtext:`\\`|||:diagtext:`function` || ||:diagtext:`a function` || |
2888| |+--------------+|+-------------------------+| |+---------------------------------+| |
2889| ||:diagtext:`@` |||:diagtext:`functiongroup`|| ||:diagtext:`a function` || |
2890| |+--------------+|+-------------------------+| |+---------------------------------+| |
2891| | ||:diagtext:`method` || ||:diagtext:`an Objective-C method`|| |
2892| | |+-------------------------+| |+---------------------------------+| |
2893| | ||:diagtext:`methodgroup` || ||:diagtext:`an Objective-C method`|| |
2894| | |+-------------------------+| |+---------------------------------+| |
2895| | ||:diagtext:`callback` || ||:diagtext:`a pointer to function`|| |
2896| | |+-------------------------+| |+---------------------------------+| |
2897+----------------------------------------+----------------+---------------------------+---------------------------------------------------------------------+-----------------------------------+-------------------------------+
2898
2899+-------------------------------------------------------------------------------------------------------+
2900|:warning:`warning:` |nbsp| :diagtext:`HTML start tag prematurely ended, expected attribute name or '>'`|
2901+-------------------------------------------------------------------------------------------------------+
2902
2903+-------------------------------------------------------------------------------+
2904|:warning:`warning:` |nbsp| :diagtext:`expected quoted string after equals sign`|
2905+-------------------------------------------------------------------------------+
2906
2907+-----------------------------------------------------------------------------------------------------+
2908|:warning:`warning:` |nbsp| :diagtext:`parameter '`:placeholder:`A`:diagtext:`' is already documented`|
2909+-----------------------------------------------------------------------------------------------------+
2910
2911+------------------------------------------------------------------------------------------------------------------------------------------+
2912|:warning:`warning:` |nbsp| :diagtext:`unrecognized parameter passing direction, valid directions are '\[in\]', '\[out\]' and '\[in,out\]'`|
2913+------------------------------------------------------------------------------------------------------------------------------------------+
2914
2915+----------------------------------------+----------------+-------------------------------------------------------------------------------------------+
2916|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|:diagtext:`param' command used in a comment that is not attached to a function declaration`|
2917| ||:diagtext:`\\`|| |
2918| |+--------------+| |
2919| ||:diagtext:`@` || |
2920| |+--------------+| |
2921+----------------------------------------+----------------+-------------------------------------------------------------------------------------------+
2922
2923+---------------------------------------------------------------------------------------------------------------------+
2924|:warning:`warning:` |nbsp| :diagtext:`parameter '`:placeholder:`A`:diagtext:`' not found in the function declaration`|
2925+---------------------------------------------------------------------------------------------------------------------+
2926
2927+----------------------------------------+----------------+-------------------------------------------------------------------------------------+-------------------------------------+
2928|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|:placeholder:`B`:diagtext:`' command used in a comment that is attached to a` |nbsp| |+-----------------------------------+|
2929| ||:diagtext:`\\`|| ||:diagtext:`function returning void`||
2930| |+--------------+| |+-----------------------------------+|
2931| ||:diagtext:`@` || ||:diagtext:`constructor` ||
2932| |+--------------+| |+-----------------------------------+|
2933| | | ||:diagtext:`destructor` ||
2934| | | |+-----------------------------------+|
2935| | | ||:diagtext:`method returning void` ||
2936| | | |+-----------------------------------+|
2937+----------------------------------------+----------------+-------------------------------------------------------------------------------------+-------------------------------------+
2938
2939+----------------------------------------+----------------+----------------------------------------------------------------------------------------------------------------+
2940|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|:placeholder:`B`:diagtext:`' command used in a comment that is not attached to a function or method declaration`|
2941| ||:diagtext:`\\`|| |
2942| |+--------------+| |
2943| ||:diagtext:`@` || |
2944| |+--------------+| |
2945+----------------------------------------+----------------+----------------------------------------------------------------------------------------------------------------+
2946
2947+--------------------------------------------------------------------------------------------------------------+
2948|:warning:`warning:` |nbsp| :diagtext:`template parameter '`:placeholder:`A`:diagtext:`' is already documented`|
2949+--------------------------------------------------------------------------------------------------------------+
2950
2951+----------------------------------------+----------------+--------------------------------------------------------------------------------------------+
2952|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|:diagtext:`tparam' command used in a comment that is not attached to a template declaration`|
2953| ||:diagtext:`\\`|| |
2954| |+--------------+| |
2955| ||:diagtext:`@` || |
2956| |+--------------+| |
2957+----------------------------------------+----------------+--------------------------------------------------------------------------------------------+
2958
2959+------------------------------------------------------------------------------------------------------------------------------+
2960|:warning:`warning:` |nbsp| :diagtext:`template parameter '`:placeholder:`A`:diagtext:`' not found in the template declaration`|
2961+------------------------------------------------------------------------------------------------------------------------------+
2962
2963+---------------------------------------------------------------------+
2964|:warning:`warning:` |nbsp| :diagtext:`not a Doxygen trailing comment`|
2965+---------------------------------------------------------------------+
2966
2967+----------------------------------------+----------------+------------------------------------------------------------------------------+
2968|:warning:`warning:` |nbsp| :diagtext:`'`|+--------------+|:placeholder:`B`:diagtext:`' command does not terminate a verbatim text block`|
2969| ||:diagtext:`\\`|| |
2970| |+--------------+| |
2971| ||:diagtext:`@` || |
2972| |+--------------+| |
2973+----------------------------------------+----------------+------------------------------------------------------------------------------+
2974
2975
2976-Wdocumentation-deprecated-sync
2977-------------------------------
2978**Diagnostic text:**
2979
2980+----------------------------------------------------------------------------------------------------------------------------------+
2981|:warning:`warning:` |nbsp| :diagtext:`declaration is marked with '\\deprecated' command but does not have a deprecation attribute`|
2982+----------------------------------------------------------------------------------------------------------------------------------+
2983
2984
2985-Wdocumentation-html
2986--------------------
2987**Diagnostic text:**
2988
2989+-----------------------------------------------------------------------------------------------+
2990|:warning:`warning:` |nbsp| :diagtext:`HTML end tag '`:placeholder:`A`:diagtext:`' is forbidden`|
2991+-----------------------------------------------------------------------------------------------+
2992
2993+--------------------------------------------------------------------------------+
2994|:warning:`warning:` |nbsp| :diagtext:`HTML end tag does not match any start tag`|
2995+--------------------------------------------------------------------------------+
2996
2997+--------------------------------------------------------------------------------------------------+
2998|:warning:`warning:` |nbsp| :diagtext:`HTML tag '`:placeholder:`A`:diagtext:`' requires an end tag`|
2999+--------------------------------------------------------------------------------------------------+
3000
3001+-----------------------------------------------------------------------------------------------------------------------------+
3002|:warning:`warning:` |nbsp| :diagtext:`HTML start tag '`:placeholder:`A`:diagtext:`' closed by '`:placeholder:`B`:diagtext:`'`|
3003+-----------------------------------------------------------------------------------------------------------------------------+
3004
3005
3006-Wdocumentation-pedantic
3007------------------------
3008Also controls `-Wdocumentation-unknown-command`_.
3009
3010**Diagnostic text:**
3011
3012+-----------------------------------------------------------------------------------------------+
3013|:warning:`warning:` |nbsp| :diagtext:`whitespace is not allowed in parameter passing direction`|
3014+-----------------------------------------------------------------------------------------------+
3015
3016
3017-Wdocumentation-unknown-command
3018-------------------------------
3019**Diagnostic text:**
3020
3021+--------------------------------------------------------------------------------------------------------------------------------------------+
3022|:warning:`warning:` |nbsp| :diagtext:`unknown command tag name '`:placeholder:`A`:diagtext:`'; did you mean '`:placeholder:`B`:diagtext:`'?`|
3023+--------------------------------------------------------------------------------------------------------------------------------------------+
3024
3025+---------------------------------------------------------------+
3026|:warning:`warning:` |nbsp| :diagtext:`unknown command tag name`|
3027+---------------------------------------------------------------+
3028
3029
3030-Wdollar-in-identifier-extension
3031--------------------------------
3032**Diagnostic text:**
3033
3034+--------------------------------------------------------+
3035|:warning:`warning:` |nbsp| :diagtext:`'$' in identifier`|
3036+--------------------------------------------------------+
3037
3038
3039-Wdouble-promotion
3040------------------
3041**Diagnostic text:**
3042
3043+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3044|:warning:`warning:` |nbsp| :diagtext:`implicit conversion increases floating-point precision:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
3045+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3046
3047
3048-Wduplicate-decl-specifier
3049--------------------------
3050This diagnostic is enabled by default.
3051
3052**Diagnostic text:**
3053
3054+-----------------------------------------------------------------------------------------------------+
3055|:warning:`warning:` |nbsp| :diagtext:`duplicate '`:placeholder:`A`:diagtext:`' declaration specifier`|
3056+-----------------------------------------------------------------------------------------------------+
3057
3058+-----------------------------------------------------------------------------------------------------+
3059|:warning:`warning:` |nbsp| :diagtext:`duplicate '`:placeholder:`A`:diagtext:`' declaration specifier`|
3060+-----------------------------------------------------------------------------------------------------+
3061
3062
3063-Wduplicate-enum
3064----------------
3065**Diagnostic text:**
3066
3067+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3068|:warning:`warning:` |nbsp| :diagtext:`element` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has been implicitly assigned` |nbsp| :placeholder:`B` |nbsp| :diagtext:`which another element has been assigned`|
3069+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3070
3071
3072-Wduplicate-method-arg
3073----------------------
3074**Diagnostic text:**
3075
3076+------------------------------------------------------------------------------------------------+
3077|:warning:`warning:` |nbsp| :diagtext:`redeclaration of method parameter` |nbsp| :placeholder:`A`|
3078+------------------------------------------------------------------------------------------------+
3079
3080
3081-Wduplicate-method-match
3082------------------------
3083**Diagnostic text:**
3084
3085+-----------------------------------------------------------------------------------------------------------------------------------+
3086|:warning:`warning:` |nbsp| :diagtext:`multiple declarations of method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`found and ignored`|
3087+-----------------------------------------------------------------------------------------------------------------------------------+
3088
3089
3090-Wdynamic-class-memaccess
3091-------------------------
3092This diagnostic is enabled by default.
3093
3094**Diagnostic text:**
3095
3096+---------------------------+-------------------------------+------------------------------------------------------------------------------------------------+----------------------------------------+---------------------------------------------------------------------------------------------+-------------------------+
3097|:warning:`warning:` |nbsp| |+-----------------------------+| |nbsp| :diagtext:`this` |nbsp| :placeholder:`B` |nbsp| :diagtext:`call is a pointer to` |nbsp| |+--------------------------------------+|:diagtext:`dynamic class` |nbsp| :placeholder:`D`:diagtext:`; vtable pointer will be` |nbsp| |+-----------------------+|
3098| ||:diagtext:`destination for` || || || ||:diagtext:`overwritten`||
3099| |+-----------------------------+| |+--------------------------------------+| |+-----------------------+|
3100| ||:diagtext:`source of` || ||:diagtext:`class containing a` |nbsp| || ||:diagtext:`copied` ||
3101| |+-----------------------------+| |+--------------------------------------+| |+-----------------------+|
3102| ||:diagtext:`first operand of` || | | ||:diagtext:`moved` ||
3103| |+-----------------------------+| | | |+-----------------------+|
3104| ||:diagtext:`second operand of`|| | | ||:diagtext:`compared` ||
3105| |+-----------------------------+| | | |+-----------------------+|
3106+---------------------------+-------------------------------+------------------------------------------------------------------------------------------------+----------------------------------------+---------------------------------------------------------------------------------------------+-------------------------+
3107
3108
3109-Weffc++
3110--------
Richard Smithce9d5862016-09-14 01:51:10 +00003111Synonym for `-Wnon-virtual-dtor`_.
3112
Richard Smithb6a3b4b2016-09-12 05:58:29 +00003113
3114-Wembedded-directive
3115--------------------
3116**Diagnostic text:**
3117
3118+----------------------------------------------------------------------------------------------------------+
3119|:warning:`warning:` |nbsp| :diagtext:`embedding a directive within macro arguments has undefined behavior`|
3120+----------------------------------------------------------------------------------------------------------+
3121
3122
3123-Wempty-body
3124------------
3125This diagnostic is enabled by default.
3126
3127**Diagnostic text:**
3128
3129+--------------------------------------------------------------+
3130|:warning:`warning:` |nbsp| :diagtext:`for loop has empty body`|
3131+--------------------------------------------------------------+
3132
3133+------------------------------------------------------------------+
3134|:warning:`warning:` |nbsp| :diagtext:`if statement has empty body`|
3135+------------------------------------------------------------------+
3136
3137+--------------------------------------------------------------------------+
3138|:warning:`warning:` |nbsp| :diagtext:`range-based for loop has empty body`|
3139+--------------------------------------------------------------------------+
3140
3141+----------------------------------------------------------------------+
3142|:warning:`warning:` |nbsp| :diagtext:`switch statement has empty body`|
3143+----------------------------------------------------------------------+
3144
3145+----------------------------------------------------------------+
3146|:warning:`warning:` |nbsp| :diagtext:`while loop has empty body`|
3147+----------------------------------------------------------------+
3148
3149
3150-Wempty-decomposition
3151---------------------
3152This diagnostic is enabled by default.
3153
3154**Diagnostic text:**
3155
3156+-------------------------------------------------------------------------------------------------+
3157|:warning:`warning:` |nbsp| :diagtext:`ISO C++1z does not allow a decomposition group to be empty`|
3158+-------------------------------------------------------------------------------------------------+
3159
3160
3161-Wempty-translation-unit
3162------------------------
3163**Diagnostic text:**
3164
3165+------------------------------------------------------------------------------------------------------------+
3166|:warning:`warning:` |nbsp| :diagtext:`ISO C requires a translation unit to contain at least one declaration`|
3167+------------------------------------------------------------------------------------------------------------+
3168
3169
3170-Wencode-type
3171-------------
3172This diagnostic is enabled by default.
3173
3174**Diagnostic text:**
3175
3176+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3177|:warning:`warning:` |nbsp| :diagtext:`encoding of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`type is incomplete because` |nbsp| :placeholder:`B` |nbsp| :diagtext:`component has unknown encoding`|
3178+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3179
3180
3181-Wendif-labels
3182--------------
3183Synonym for `-Wextra-tokens`_.
3184
3185
3186-Wenum-compare
3187--------------
3188This diagnostic is enabled by default.
3189
3190**Diagnostic text:**
3191
3192+------------------------------------------------------------------------------------------------+
3193|:warning:`warning:` |nbsp| :diagtext:`comparison of two values with different enumeration types`|
3194+------------------------------------------------------------------------------------------------+
3195
3196
3197-Wenum-conversion
3198-----------------
3199This diagnostic is enabled by default.
3200
3201**Diagnostic text:**
3202
3203+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3204|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from enumeration type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to different enumeration type` |nbsp| :placeholder:`B`|
3205+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3206
3207
3208-Wenum-too-large
3209----------------
3210This diagnostic is enabled by default.
3211
3212**Diagnostic text:**
3213
3214+-----------------------------------------------------------------------------------------+
3215|:warning:`warning:` |nbsp| :diagtext:`enumeration values exceed range of largest integer`|
3216+-----------------------------------------------------------------------------------------+
3217
3218+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
3219|:warning:`warning:` |nbsp| :diagtext:`incremented enumerator value` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not representable in the largest integer type`|
3220+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
3221
3222
3223-Wexceptions
3224------------
3225This diagnostic is enabled by default.
3226
3227**Diagnostic text:**
3228
3229+--------------------------------------------------------------------------------------------------------+-------------------------+--------------------------------------+
3230|:warning:`warning:` |nbsp| :diagtext:`cannot refer to a non-static member from the handler of a` |nbsp| |+-----------------------+| |nbsp| :diagtext:`function try block`|
3231| ||:diagtext:`constructor`|| |
3232| |+-----------------------+| |
3233| ||:diagtext:`destructor` || |
3234| |+-----------------------+| |
3235+--------------------------------------------------------------------------------------------------------+-------------------------+--------------------------------------+
3236
3237+-------------------------------------------------------------------------------------------------------------------------------------+
3238|:warning:`warning:` |nbsp| :diagtext:`exception of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will be caught by earlier handler`|
3239+-------------------------------------------------------------------------------------------------------------------------------------+
3240
3241
3242-Wexit-time-destructors
3243-----------------------
3244**Diagnostic text:**
3245
3246+-----------------------------------------------------------------------------------+
3247|:warning:`warning:` |nbsp| :diagtext:`declaration requires an exit-time destructor`|
3248+-----------------------------------------------------------------------------------+
3249
3250
3251-Wexpansion-to-defined
3252----------------------
3253Some of the diagnostics controlled by this flag are enabled by default.
3254
3255**Diagnostic text:**
3256
3257+-------------------------------------------------------------------------------------------------+
3258|:warning:`warning:` |nbsp| :diagtext:`macro expansion producing 'defined' has undefined behavior`|
3259+-------------------------------------------------------------------------------------------------+
3260
3261+-------------------------------------------------------------------------------------------------+
3262|:warning:`warning:` |nbsp| :diagtext:`macro expansion producing 'defined' has undefined behavior`|
3263+-------------------------------------------------------------------------------------------------+
3264
3265
3266-Wexplicit-initialize-call
3267--------------------------
3268This diagnostic is enabled by default.
3269
3270**Diagnostic text:**
3271
3272+------------------------------------------------------------------------------------------------------------+
3273|:warning:`warning:` |nbsp| :diagtext:`explicit call to +initialize results in duplicate call to +initialize`|
3274+------------------------------------------------------------------------------------------------------------+
3275
3276+----------------------------------------------------------------------------------------------------------------------------+
3277|:warning:`warning:` |nbsp| :diagtext:`explicit call to \[super initialize\] should only be in implementation of +initialize`|
3278+----------------------------------------------------------------------------------------------------------------------------+
3279
3280
3281-Wexplicit-ownership-type
3282-------------------------
3283**Diagnostic text:**
3284
3285+-------------------------------------------------------------------------------------------------------------------------------------+
3286|:warning:`warning:` |nbsp| :diagtext:`method parameter of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with no explicit ownership`|
3287+-------------------------------------------------------------------------------------------------------------------------------------+
3288
3289
3290-Wextended-offsetof
3291-------------------
3292**Diagnostic text:**
3293
3294+--------------------------------------------------------------------------------------+
3295|:warning:`warning:` |nbsp| :diagtext:`using extended field designator is an extension`|
3296+--------------------------------------------------------------------------------------+
3297
3298
3299-Wextern-c-compat
3300-----------------
3301This diagnostic is enabled by default.
3302
3303**Diagnostic text:**
3304
3305+---------------------------+---------------------------+--------------------+--------------------------------------------+---------------------------+--------------------------+
3306|:warning:`warning:` |nbsp| |+-------------------------+|+------------------+| |nbsp| :diagtext:`has size 0 in C,` |nbsp| |+-------------------------+| |nbsp| :diagtext:`in C++`|
3307| || |||:diagtext:`struct`|| ||:diagtext:`size 1` || |
3308| |+-------------------------+|+------------------+| |+-------------------------+| |
3309| ||:diagtext:`empty` |nbsp| |||:diagtext:`union` || ||:diagtext:`non-zero size`|| |
3310| |+-------------------------+|+------------------+| |+-------------------------+| |
3311+---------------------------+---------------------------+--------------------+--------------------------------------------+---------------------------+--------------------------+
3312
3313
3314-Wextern-initializer
3315--------------------
3316This diagnostic is enabled by default.
3317
3318**Diagnostic text:**
3319
3320+---------------------------------------------------------------------------+
3321|:warning:`warning:` |nbsp| :diagtext:`'extern' variable has an initializer`|
3322+---------------------------------------------------------------------------+
3323
3324
3325-Wextra
3326-------
3327Some of the diagnostics controlled by this flag are enabled by default.
3328
3329Controls `-Wmissing-field-initializers`_, `-Wignored-qualifiers`_, `-Winitializer-overrides`_, `-Wsemicolon-before-method-body`_, `-Wmissing-method-return-type`_, `-Wsign-compare`_, `-Wunused-parameter`_.
3330
3331
3332-Wextra-qualification
3333---------------------
3334This diagnostic is enabled by default.
3335
3336**Diagnostic text:**
3337
3338+--------------------------------------------------------------------------------------------+
3339|:warning:`warning:` |nbsp| :diagtext:`extra qualification on member` |nbsp| :placeholder:`A`|
3340+--------------------------------------------------------------------------------------------+
3341
3342
3343-Wextra-semi
3344------------
3345Also controls `-Wc++11-extra-semi`_.
3346
3347**Diagnostic text:**
3348
3349+--------------------------------------------------------+------------------------------------------------+
3350|:warning:`warning:` |nbsp| :diagtext:`extra ';'` |nbsp| |+----------------------------------------------+|
3351| ||:diagtext:`outside of a function` ||
3352| |+----------------------------------------------+|
3353| ||+--------------------------------------------+||
3354| |||:diagtext:`inside a` |nbsp| :placeholder:`B`|||
3355| ||+--------------------------------------------+||
3356| |+----------------------------------------------+|
3357| ||:diagtext:`inside instance variable list` ||
3358| |+----------------------------------------------+|
3359| ||:diagtext:`after member function definition` ||
3360| |+----------------------------------------------+|
3361+--------------------------------------------------------+------------------------------------------------+
3362
3363+---------------------------------------------------------------------------------+
3364|:warning:`warning:` |nbsp| :diagtext:`extra ';' after member function definition`|
3365+---------------------------------------------------------------------------------+
3366
3367
3368-Wextra-tokens
3369--------------
3370This diagnostic is enabled by default.
3371
3372**Diagnostic text:**
3373
3374+------------------------------------------------------------------------------------------------------------+
3375|:warning:`warning:` |nbsp| :diagtext:`extra tokens at end of #`:placeholder:`A` |nbsp| :diagtext:`directive`|
3376+------------------------------------------------------------------------------------------------------------+
3377
3378+-------------------------------------------------------------------------------------------------------------------------------+
3379|:warning:`warning:` |nbsp| :diagtext:`extra tokens at the end of '#pragma omp` |nbsp| :placeholder:`A`:diagtext:`' are ignored`|
3380+-------------------------------------------------------------------------------------------------------------------------------+
3381
3382
3383-Wfallback
3384----------
3385This diagnostic is enabled by default.
3386
3387**Diagnostic text:**
3388
3389+------------------------------------------------------------------------------+
3390|:warning:`warning:` |nbsp| :diagtext:`falling back to` |nbsp| :placeholder:`A`|
3391+------------------------------------------------------------------------------+
3392
3393
3394-Wflag-enum
3395-----------
3396This diagnostic is enabled by default.
3397
3398**Diagnostic text:**
3399
3400+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3401|:warning:`warning:` |nbsp| :diagtext:`enumeration value` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is out of range of flags in enumeration type` |nbsp| :placeholder:`B`|
3402+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3403
3404
3405-Wflexible-array-extensions
3406---------------------------
3407**Diagnostic text:**
3408
3409+-------------------------------------------------------------------------------------------------------------------------------+
3410|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may not be used as an array element due to flexible array member`|
3411+-------------------------------------------------------------------------------------------------------------------------------+
3412
3413+-------------------------------------------------------------------------------------------------------------------------+
3414|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may not be nested in a struct due to flexible array member`|
3415+-------------------------------------------------------------------------------------------------------------------------+
3416
3417
3418-Wfloat-conversion
3419------------------
3420Also controls `-Wfloat-overflow-conversion`_, `-Wfloat-zero-conversion`_.
3421
3422**Diagnostic text:**
3423
3424+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3425|:warning:`warning:` |nbsp| :diagtext:`implicit conversion turns floating-point number into integer:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
3426+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3427
3428
3429-Wfloat-equal
3430-------------
3431**Diagnostic text:**
3432
3433+---------------------------------------------------------------------------------------+
3434|:warning:`warning:` |nbsp| :diagtext:`comparing floating point with == or != is unsafe`|
3435+---------------------------------------------------------------------------------------+
3436
3437
3438-Wfloat-overflow-conversion
3439---------------------------
3440**Diagnostic text:**
3441
3442+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3443|:warning:`warning:` |nbsp| :diagtext:`implicit conversion of out of range value from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`changes value from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D`|
3444+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3445
3446
3447-Wfloat-zero-conversion
3448-----------------------
3449**Diagnostic text:**
3450
3451+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3452|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`changes non-zero value from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D`|
3453+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3454
3455
3456-Wfor-loop-analysis
3457-------------------
3458**Diagnostic text:**
3459
3460+-----------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------+
3461|:warning:`warning:` |nbsp| :diagtext:`variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is` |nbsp| |+-----------------------+| |nbsp| :diagtext:`both in the loop header and in the loop body`|
3462| ||:diagtext:`decremented`|| |
3463| |+-----------------------+| |
3464| ||:diagtext:`incremented`|| |
3465| |+-----------------------+| |
3466+-----------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------+
3467
3468+-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------+
3469|:warning:`warning:` |nbsp| :diagtext:`variable`|+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |nbsp| :diagtext:`used in loop condition not modified in loop body`|
3470| ||:diagtext:`s` || |
3471| |+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |
3472| ||+------------------------+ || |
3473| ||| |nbsp| :placeholder:`B`| || |
3474| ||+------------------------+ || |
3475| |+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |
3476| ||+------------------------------------------------------------------------------------+ || |
3477| |||:diagtext:`s` |nbsp| :placeholder:`B` |nbsp| :diagtext:`and` |nbsp| :placeholder:`C`| || |
3478| ||+------------------------------------------------------------------------------------+ || |
3479| |+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |
3480| ||+-------------------------------------------------------------------------------------------------------------------+ || |
3481| |||:diagtext:`s` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`, and` |nbsp| :placeholder:`D`| || |
3482| ||+-------------------------------------------------------------------------------------------------------------------+ || |
3483| |+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |
3484| ||+--------------------------------------------------------------------------------------------------------------------------------------------------------+|| |
3485| |||:diagtext:`s` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`,` |nbsp| :placeholder:`D`:diagtext:`, and` |nbsp| :placeholder:`E`||| |
3486| ||+--------------------------------------------------------------------------------------------------------------------------------------------------------+|| |
3487| |+----------------------------------------------------------------------------------------------------------------------------------------------------------+| |
3488+-----------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------------------------------------+
3489
3490
3491-Wformat
3492--------
3493This diagnostic is enabled by default.
3494
3495Also controls `-Wformat-extra-args`_, `-Wformat-zero-length`_, `-Wnonnull`_, `-Wformat-security`_, `-Wformat-y2k`_, `-Wformat-invalid-specifier`_.
3496
3497**Diagnostic text:**
3498
3499+---------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3500|:warning:`warning:` |nbsp| |+--------------------------------------------+| |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' should not be used as format arguments; add an explicit cast to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`instead`|
3501| ||:diagtext:`values of type` || |
3502| |+--------------------------------------------+| |
3503| ||:diagtext:`enum values with underlying type`|| |
3504| |+--------------------------------------------+| |
3505+---------------------------+----------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3506
3507+------------------------------------------------------------------------------------------------------------------------------------+-----------------------------+------------------------+
3508|:warning:`warning:` |nbsp| :diagtext:`format specifies type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`but the argument has` |nbsp| |+---------------------------+| |nbsp| :placeholder:`B`|
3509| ||:diagtext:`type` || |
3510| |+---------------------------+| |
3511| ||:diagtext:`underlying type`|| |
3512| |+---------------------------+| |
3513+------------------------------------------------------------------------------------------------------------------------------------+-----------------------------+------------------------+
3514
3515+-----------------------------------------------------------------------------+-----------------------------+
3516|:warning:`warning:` |nbsp| :diagtext:`invalid position specified for` |nbsp| |+---------------------------+|
3517| ||:diagtext:`field width` ||
3518| |+---------------------------+|
3519| ||:diagtext:`field precision`||
3520| |+---------------------------+|
3521+-----------------------------------------------------------------------------+-----------------------------+
3522
3523+----------------------------------------------------------------------------------------------------------+
3524|:warning:`warning:` |nbsp| :diagtext:`cannot mix positional and non-positional arguments in format string`|
3525+----------------------------------------------------------------------------------------------------------+
3526
3527+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3528|:warning:`warning:` |nbsp| :diagtext:`length modifier '`:placeholder:`A`:diagtext:`' results in undefined behavior or no effect with '`:placeholder:`B`:diagtext:`' conversion specifier`|
3529+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3530
3531+--------------------------------------------------------------------------------+
3532|:warning:`warning:` |nbsp| :diagtext:`format string should not be a wide string`|
3533+--------------------------------------------------------------------------------+
3534
3535+-------------------------------------------------------------------------------------------------------+
3536|:warning:`warning:` |nbsp| :diagtext:`position arguments in format strings start counting at 1 (not 0)`|
3537+-------------------------------------------------------------------------------------------------------+
3538
3539+------------------------------------------------------------+
3540|:warning:`warning:` |nbsp| :diagtext:`format string missing`|
3541+------------------------------------------------------------+
3542
3543+----------------------------------------------------------------------------------------------------------------------------------+
3544|:warning:`warning:` |nbsp| :diagtext:`object format flags cannot be used with '`:placeholder:`A`:diagtext:`' conversion specifier`|
3545+----------------------------------------------------------------------------------------------------------------------------------+
3546
3547+----------------------------------------+-----------------+-------------------------------------+-----------------------+--------------------------------------------------------+
3548|:warning:`warning:` |nbsp| :diagtext:`'`|+---------------+|:diagtext:`' specified field` |nbsp| |+---------------------+| |nbsp| :diagtext:`is missing a matching 'int' argument`|
3549| ||:diagtext:`\*` || ||:diagtext:`width` || |
3550| |+---------------+| |+---------------------+| |
3551| ||:diagtext:`.\*`|| ||:diagtext:`precision`|| |
3552| |+---------------+| |+---------------------+| |
3553+----------------------------------------+-----------------+-------------------------------------+-----------------------+--------------------------------------------------------+
3554
3555+----------------------------------------------------+-----------------------+-----------------------------------------------------------------------------------------------------------------------+
3556|:warning:`warning:` |nbsp| :diagtext:`field` |nbsp| |+---------------------+| |nbsp| :diagtext:`should have type` |nbsp| :placeholder:`B`:diagtext:`, but argument has type` |nbsp| :placeholder:`C`|
3557| ||:diagtext:`width` || |
3558| |+---------------------+| |
3559| ||:diagtext:`precision`|| |
3560| |+---------------------+| |
3561+----------------------------------------------------+-----------------------+-----------------------------------------------------------------------------------------------------------------------+
3562
3563+-----------------------------------------------------------------+
3564|:warning:`warning:` |nbsp| :diagtext:`missing object format flag`|
3565+-----------------------------------------------------------------+
3566
3567+------------------------------------------------------------------------------------------+
3568|:warning:`warning:` |nbsp| :diagtext:`format string contains '\\0' within the string body`|
3569+------------------------------------------------------------------------------------------+
3570
3571+---------------------------------------------------------------------------+
3572|:warning:`warning:` |nbsp| :diagtext:`format string is not null-terminated`|
3573+---------------------------------------------------------------------------+
3574
3575+-----------------------------------------------------------------------------------------------------------------------------------------+
3576|:warning:`warning:` |nbsp| :diagtext:`flag '`:placeholder:`A`:diagtext:`' is ignored when flag '`:placeholder:`B`:diagtext:`' is present`|
3577+-----------------------------------------------------------------------------------------------------------------------------------------+
3578
3579+------------------------------------------------------------------+
3580|:warning:`warning:` |nbsp| :diagtext:`incomplete format specifier`|
3581+------------------------------------------------------------------+
3582
3583+--------------------------------------------------------------------------------+
3584|:warning:`warning:` |nbsp| :diagtext:`more '%%' conversions than data arguments`|
3585+--------------------------------------------------------------------------------+
3586
3587+-------------------------------------------------------------------------------------------------------+
3588|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' is not a valid object format flag`|
3589+-------------------------------------------------------------------------------------------------------+
3590
3591+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
3592|:warning:`warning:` |nbsp| :diagtext:`flag '`:placeholder:`A`:diagtext:`' results in undefined behavior with '`:placeholder:`B`:diagtext:`' conversion specifier`|
3593+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
3594
3595+---------------------------+-------------------------+------------------------------------------------------------------------------------------------------------------+
3596|:warning:`warning:` |nbsp| |+-----------------------+| |nbsp| :diagtext:`used with '`:placeholder:`B`:diagtext:`' conversion specifier, resulting in undefined behavior`|
3597| ||:diagtext:`field width`|| |
3598| |+-----------------------+| |
3599| ||:diagtext:`precision` || |
3600| |+-----------------------+| |
3601+---------------------------+-------------------------+------------------------------------------------------------------------------------------------------------------+
3602
3603+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
3604|:warning:`warning:` |nbsp| :diagtext:`data argument position '`:placeholder:`A`:diagtext:`' exceeds the number of data arguments (`:placeholder:`B`:diagtext:`)`|
3605+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
3606
3607+----------------------------------------------------------------------------------------+
3608|:warning:`warning:` |nbsp| :diagtext:`zero field width in scanf format string is unused`|
3609+----------------------------------------------------------------------------------------+
3610
3611+----------------------------------------------------------------------------------------+
3612|:warning:`warning:` |nbsp| :diagtext:`no closing '\]' for '%%\[' in scanf format string`|
3613+----------------------------------------------------------------------------------------+
3614
3615
3616-Wformat-extra-args
3617-------------------
3618This diagnostic is enabled by default.
3619
3620**Diagnostic text:**
3621
3622+------------------------------------------------------------------------------+
3623|:warning:`warning:` |nbsp| :diagtext:`data argument not used by format string`|
3624+------------------------------------------------------------------------------+
3625
3626
3627-Wformat-invalid-specifier
3628--------------------------
3629This diagnostic is enabled by default.
3630
3631**Diagnostic text:**
3632
3633+--------------------------------------------------------------------------------------------------+
3634|:warning:`warning:` |nbsp| :diagtext:`invalid conversion specifier '`:placeholder:`A`:diagtext:`'`|
3635+--------------------------------------------------------------------------------------------------+
3636
3637
3638-Wformat-non-iso
3639----------------
3640**Diagnostic text:**
3641
3642+-----------------------------------------------------------------------------+----------------------------------+---------------------------------------------+
3643|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`'` |nbsp| |+--------------------------------+| |nbsp| :diagtext:`is not supported by ISO C`|
3644| ||:diagtext:`length modifier` || |
3645| |+--------------------------------+| |
3646| ||:diagtext:`conversion specifier`|| |
3647| |+--------------------------------+| |
3648+-----------------------------------------------------------------------------+----------------------------------+---------------------------------------------+
3649
3650+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3651|:warning:`warning:` |nbsp| :diagtext:`using length modifier '`:placeholder:`A`:diagtext:`' with conversion specifier '`:placeholder:`B`:diagtext:`' is not supported by ISO C`|
3652+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
3653
3654+--------------------------------------------------------------------------------------+
3655|:warning:`warning:` |nbsp| :diagtext:`positional arguments are not supported by ISO C`|
3656+--------------------------------------------------------------------------------------+
3657
3658
3659-Wformat-nonliteral
3660-------------------
3661**Diagnostic text:**
3662
3663+----------------------------------------------------------------------------+
3664|:warning:`warning:` |nbsp| :diagtext:`format string is not a string literal`|
3665+----------------------------------------------------------------------------+
3666
3667
3668-Wformat-pedantic
3669-----------------
3670**Diagnostic text:**
3671
3672+------------------------------------------------------------------------------------------------------------------------------------+-----------------------------+------------------------+
3673|:warning:`warning:` |nbsp| :diagtext:`format specifies type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`but the argument has` |nbsp| |+---------------------------+| |nbsp| :placeholder:`B`|
3674| ||:diagtext:`type` || |
3675| |+---------------------------+| |
3676| ||:diagtext:`underlying type`|| |
3677| |+---------------------------+| |
3678+------------------------------------------------------------------------------------------------------------------------------------+-----------------------------+------------------------+
3679
3680
3681-Wformat-security
3682-----------------
3683This diagnostic is enabled by default.
3684
3685**Diagnostic text:**
3686
3687+---------------------------------------------------------------------------------------------------+
3688|:warning:`warning:` |nbsp| :diagtext:`format string is not a string literal (potentially insecure)`|
3689+---------------------------------------------------------------------------------------------------+
3690
3691
3692-Wformat-y2k
3693------------
3694This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
3695
3696-Wformat-zero-length
3697--------------------
3698This diagnostic is enabled by default.
3699
3700**Diagnostic text:**
3701
3702+-------------------------------------------------------------+
3703|:warning:`warning:` |nbsp| :diagtext:`format string is empty`|
3704+-------------------------------------------------------------+
3705
3706
3707-Wformat=2
3708----------
3709Some of the diagnostics controlled by this flag are enabled by default.
3710
3711Controls `-Wformat-nonliteral`_, `-Wformat-security`_, `-Wformat-y2k`_.
3712
3713
3714-Wfour-char-constants
3715---------------------
3716**Diagnostic text:**
3717
3718+-------------------------------------------------------------------------+
3719|:warning:`warning:` |nbsp| :diagtext:`multi-character character constant`|
3720+-------------------------------------------------------------------------+
3721
3722
3723-Wframe-larger-than=
3724--------------------
3725This diagnostic is enabled by default.
3726
3727**Diagnostic text:**
3728
3729The text of this diagnostic is not controlled by Clang.
3730
3731+--------------------------------------------------------------------------------------------------------------------------------------+
3732|:warning:`warning:` |nbsp| :diagtext:`stack frame size of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`bytes in` |nbsp| :placeholder:`B`|
3733+--------------------------------------------------------------------------------------------------------------------------------------+
3734
3735
3736-Wfunction-def-in-objc-container
3737--------------------------------
3738This diagnostic is enabled by default.
3739
3740**Diagnostic text:**
3741
3742+--------------------------------------------------------------------------------------------------------+
3743|:warning:`warning:` |nbsp| :diagtext:`function definition inside an Objective-C container is deprecated`|
3744+--------------------------------------------------------------------------------------------------------+
3745
3746
3747-Wfuture-compat
3748---------------
3749This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
3750
3751-Wgcc-compat
3752------------
3753Some of the diagnostics controlled by this flag are enabled by default.
3754
3755**Diagnostic text:**
3756
3757+------------------------------------------------------------------------+
3758|:warning:`warning:` |nbsp| :diagtext:`'enable\_if' is a clang extension`|
3759+------------------------------------------------------------------------+
3760
3761+-----------------------------------------------------------------------------------------------+
3762|:warning:`warning:` |nbsp| :diagtext:`\_\_final is a GNU extension, consider using C++11 final`|
3763+-----------------------------------------------------------------------------------------------+
3764
3765+--------------------------------------------------------------------------------------------------------------------------------------------------------+
3766|:warning:`warning:` |nbsp| :diagtext:`GCC does not allow` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute in this position on a function definition`|
3767+--------------------------------------------------------------------------------------------------------------------------------------------------------+
3768
3769+---------------------------------------------------------------------------------------+
3770|:warning:`warning:` |nbsp| :diagtext:`'break' is bound to loop, GCC binds it to switch`|
3771+---------------------------------------------------------------------------------------+
3772
3773+----------------------------------------------------------------------------------------------------------------------------------------+
3774|:warning:`warning:` |nbsp| :diagtext:`GCC does not allow the 'cleanup' attribute argument to be anything other than a simple identifier`|
3775+----------------------------------------------------------------------------------------------------------------------------------------+
3776
3777+-----------------------------------------------------------------------------------------------------------------+
3778|:warning:`warning:` |nbsp| :diagtext:`GCC does not allow an attribute in this position on a function declaration`|
3779+-----------------------------------------------------------------------------------------------------------------+
3780
3781+----------------------------------------------------------------------------------------------------------------------------------+
3782|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' is bound to current loop, GCC binds it to the enclosing loop`|
3783+----------------------------------------------------------------------------------------------------------------------------------+
3784
3785
3786-Wglobal-constructors
3787---------------------
3788**Diagnostic text:**
3789
3790+--------------------------------------------------------------------------------+
3791|:warning:`warning:` |nbsp| :diagtext:`declaration requires a global constructor`|
3792+--------------------------------------------------------------------------------+
3793
3794+-------------------------------------------------------------------------------+
3795|:warning:`warning:` |nbsp| :diagtext:`declaration requires a global destructor`|
3796+-------------------------------------------------------------------------------+
3797
3798
3799-Wgnu
3800-----
3801Some of the diagnostics controlled by this flag are enabled by default.
3802
3803Controls `-Wgnu-alignof-expression`_, `-Wgnu-anonymous-struct`_, `-Wgnu-auto-type`_, `-Wgnu-binary-literal`_, `-Wgnu-case-range`_, `-Wgnu-complex-integer`_, `-Wgnu-compound-literal-initializer`_, `-Wgnu-conditional-omitted-operand`_, `-Wgnu-designator`_, `-Wgnu-empty-initializer`_, `-Wgnu-empty-struct`_, `-Wvla-extension`_, `-Wgnu-flexible-array-initializer`_, `-Wgnu-flexible-array-union-member`_, `-Wgnu-folding-constant`_, `-Wgnu-imaginary-constant`_, `-Wgnu-include-next`_, `-Wgnu-label-as-value`_, `-Wredeclared-class-member`_, `-Wgnu-redeclared-enum`_, `-Wgnu-statement-expression`_, `-Wgnu-static-float-init`_, `-Wgnu-string-literal-operator-template`_, `-Wgnu-union-cast`_, `-Wgnu-variable-sized-type-not-at-end`_, `-Wzero-length-array`_, `-Wgnu-zero-line-directive`_, `-Wgnu-zero-variadic-macro-arguments`_.
3804
3805
3806-Wgnu-alignof-expression
3807------------------------
3808This diagnostic is enabled by default.
3809
3810**Diagnostic text:**
3811
3812+----------------------------------------------------------------------------------------------------------+
3813|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`applied to an expression is a GNU extension`|
3814+----------------------------------------------------------------------------------------------------------+
3815
3816
3817-Wgnu-anonymous-struct
3818----------------------
3819**Diagnostic text:**
3820
3821+----------------------------------------------------------------------------+
3822|:warning:`warning:` |nbsp| :diagtext:`anonymous structs are a GNU extension`|
3823+----------------------------------------------------------------------------+
3824
3825
3826-Wgnu-array-member-paren-init
3827-----------------------------
3828This diagnostic is an error by default, but the flag ``-Wno-gnu-array-member-paren-init`` can be used to disable the error.
3829
3830**Diagnostic text:**
3831
3832+----------------------------------------------------------------------------------------------------+
3833|:error:`error:` |nbsp| :diagtext:`parenthesized initialization of a member array is a GNU extension`|
3834+----------------------------------------------------------------------------------------------------+
3835
3836
3837-Wgnu-auto-type
3838---------------
3839**Diagnostic text:**
3840
3841+--------------------------------------------------------------------------+
3842|:warning:`warning:` |nbsp| :diagtext:`'\_\_auto\_type' is a GNU extension`|
3843+--------------------------------------------------------------------------+
3844
3845
3846-Wgnu-binary-literal
3847--------------------
3848**Diagnostic text:**
3849
3850+----------------------------------------------------------------------------------+
3851|:warning:`warning:` |nbsp| :diagtext:`binary integer literals are a GNU extension`|
3852+----------------------------------------------------------------------------------+
3853
3854
3855-Wgnu-case-range
3856----------------
3857**Diagnostic text:**
3858
3859+----------------------------------------------------------------------+
3860|:warning:`warning:` |nbsp| :diagtext:`use of GNU case range extension`|
3861+----------------------------------------------------------------------+
3862
3863
3864-Wgnu-complex-integer
3865---------------------
3866**Diagnostic text:**
3867
3868+--------------------------------------------------------------------------------+
3869|:warning:`warning:` |nbsp| :diagtext:`complex integer types are a GNU extension`|
3870+--------------------------------------------------------------------------------+
3871
3872
3873-Wgnu-compound-literal-initializer
3874----------------------------------
3875**Diagnostic text:**
3876
3877+--------------------------------------------------------------------------------------------------------------------------------------------------+
3878|:warning:`warning:` |nbsp| :diagtext:`initialization of an array` |nbsp| :diagtext:`from a compound literal` |nbsp| :diagtext:`is a GNU extension`|
3879+--------------------------------------------------------------------------------------------------------------------------------------------------+
3880
3881
3882-Wgnu-conditional-omitted-operand
3883---------------------------------
3884**Diagnostic text:**
3885
3886+--------------------------------------------------------------------------------------------------------------+
3887|:warning:`warning:` |nbsp| :diagtext:`use of GNU ?: conditional expression extension, omitting middle operand`|
3888+--------------------------------------------------------------------------------------------------------------+
3889
3890
3891-Wgnu-designator
3892----------------
3893Some of the diagnostics controlled by this flag are enabled by default.
3894
3895**Diagnostic text:**
3896
3897+-----------------------------------------------------------------------+
3898|:warning:`warning:` |nbsp| :diagtext:`use of GNU array range extension`|
3899+-----------------------------------------------------------------------+
3900
3901+-------------------------------------------------------------------------------------+
3902|:warning:`warning:` |nbsp| :diagtext:`use of GNU 'missing =' extension in designator`|
3903+-------------------------------------------------------------------------------------+
3904
3905+--------------------------------------------------------------------------------------+
3906|:warning:`warning:` |nbsp| :diagtext:`use of GNU old-style field designator extension`|
3907+--------------------------------------------------------------------------------------+
3908
3909
3910-Wgnu-empty-initializer
3911-----------------------
3912**Diagnostic text:**
3913
3914+-----------------------------------------------------------------------------+
3915|:warning:`warning:` |nbsp| :diagtext:`use of GNU empty initializer extension`|
3916+-----------------------------------------------------------------------------+
3917
3918
3919-Wgnu-empty-struct
3920------------------
3921**Diagnostic text:**
3922
3923+----------------------------------------------------+--------------------+--------------------------------------+
3924|:warning:`warning:` |nbsp| :diagtext:`empty` |nbsp| |+------------------+| |nbsp| :diagtext:`is a GNU extension`|
3925| ||:diagtext:`struct`|| |
3926| |+------------------+| |
3927| ||:diagtext:`union` || |
3928| |+------------------+| |
3929+----------------------------------------------------+--------------------+--------------------------------------+
3930
3931+----------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------+
3932|:warning:`warning:` |nbsp| :diagtext:`flexible array member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in otherwise empty` |nbsp| |+---------------------+| |nbsp| :diagtext:`is a GNU extension`|
3933| ||:diagtext:`struct` || |
3934| |+---------------------+| |
3935| ||:diagtext:`interface`|| |
3936| |+---------------------+| |
3937| ||:diagtext:`union` || |
3938| |+---------------------+| |
3939| ||:diagtext:`class` || |
3940| |+---------------------+| |
3941| ||:diagtext:`enum` || |
3942| |+---------------------+| |
3943+----------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------+
3944
3945+---------------------------+--------------------+------------------------------------------------------------+
3946|:warning:`warning:` |nbsp| |+------------------+| |nbsp| :diagtext:`without named members is a GNU extension`|
3947| ||:diagtext:`struct`|| |
3948| |+------------------+| |
3949| ||:diagtext:`union` || |
3950| |+------------------+| |
3951+---------------------------+--------------------+------------------------------------------------------------+
3952
3953
3954-Wgnu-flexible-array-initializer
3955--------------------------------
3956**Diagnostic text:**
3957
3958+---------------------------------------------------------------------------------------+
3959|:warning:`warning:` |nbsp| :diagtext:`flexible array initialization is a GNU extension`|
3960+---------------------------------------------------------------------------------------+
3961
3962
3963-Wgnu-flexible-array-union-member
3964---------------------------------
3965**Diagnostic text:**
3966
3967+-------------------------------------------------------------------------------------------------------------------------------------+
3968|:warning:`warning:` |nbsp| :diagtext:`flexible array member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in a union is a GNU extension`|
3969+-------------------------------------------------------------------------------------------------------------------------------------+
3970
3971
3972-Wgnu-folding-constant
3973----------------------
3974**Diagnostic text:**
3975
3976+-------------------------------------------------------------------+----------------------+------------------------------------------------------------------------------------+
3977|:warning:`warning:` |nbsp| :diagtext:`expression is not an` |nbsp| |+--------------------+| |nbsp| :diagtext:`constant expression; folding it to a constant is a GNU extension`|
3978| ||:diagtext:`integer` || |
3979| |+--------------------+| |
3980| ||:diagtext:`integral`|| |
3981| |+--------------------+| |
3982+-------------------------------------------------------------------+----------------------+------------------------------------------------------------------------------------+
3983
3984+------------------------------------------------------------------------------------------------------------------------------------------------------------+
3985|:warning:`warning:` |nbsp| :diagtext:`in-class initializer for static data member is not a constant expression; folding it to a constant is a GNU extension`|
3986+------------------------------------------------------------------------------------------------------------------------------------------------------------+
3987
3988+-----------------------------------------------------------------------------------------------------+
3989|:warning:`warning:` |nbsp| :diagtext:`variable length array folded to constant array as an extension`|
3990+-----------------------------------------------------------------------------------------------------+
3991
3992
3993-Wgnu-imaginary-constant
3994------------------------
3995**Diagnostic text:**
3996
3997+------------------------------------------------------------------------------+
3998|:warning:`warning:` |nbsp| :diagtext:`imaginary constants are a GNU extension`|
3999+------------------------------------------------------------------------------+
4000
4001
4002-Wgnu-include-next
4003------------------
4004**Diagnostic text:**
4005
4006+-----------------------------------------------------------------------------+
4007|:warning:`warning:` |nbsp| :diagtext:`#include\_next is a language extension`|
4008+-----------------------------------------------------------------------------+
4009
4010
4011-Wgnu-label-as-value
4012--------------------
4013**Diagnostic text:**
4014
4015+----------------------------------------------------------------------------+
4016|:warning:`warning:` |nbsp| :diagtext:`use of GNU address-of-label extension`|
4017+----------------------------------------------------------------------------+
4018
4019+-------------------------------------------------------------------------+
4020|:warning:`warning:` |nbsp| :diagtext:`use of GNU indirect-goto extension`|
4021+-------------------------------------------------------------------------+
4022
4023
4024-Wgnu-redeclared-enum
4025---------------------
4026**Diagnostic text:**
4027
4028+------------------------------------------------------------------------------------------------------------------------------------------+
4029|:warning:`warning:` |nbsp| :diagtext:`redeclaration of already-defined enum` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a GNU extension`|
4030+------------------------------------------------------------------------------------------------------------------------------------------+
4031
4032
4033-Wgnu-statement-expression
4034--------------------------
4035**Diagnostic text:**
4036
4037+--------------------------------------------------------------------------------+
4038|:warning:`warning:` |nbsp| :diagtext:`use of GNU statement expression extension`|
4039+--------------------------------------------------------------------------------+
4040
4041
4042-Wgnu-static-float-init
4043-----------------------
4044This diagnostic is enabled by default.
4045
4046**Diagnostic text:**
4047
4048+--------------------------------------------------------------------------------------------------------------------------------------------------------+
4049|:warning:`warning:` |nbsp| :diagtext:`in-class initializer for static data member of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a GNU extension`|
4050+--------------------------------------------------------------------------------------------------------------------------------------------------------+
4051
4052
4053-Wgnu-string-literal-operator-template
4054--------------------------------------
4055This diagnostic is enabled by default.
4056
4057**Diagnostic text:**
4058
4059+--------------------------------------------------------------------------------------------+
4060|:warning:`warning:` |nbsp| :diagtext:`string literal operator templates are a GNU extension`|
4061+--------------------------------------------------------------------------------------------+
4062
4063
4064-Wgnu-union-cast
4065----------------
4066**Diagnostic text:**
4067
4068+----------------------------------------------------------------------------+
4069|:warning:`warning:` |nbsp| :diagtext:`cast to union type is a GNU extension`|
4070+----------------------------------------------------------------------------+
4071
4072
4073-Wgnu-variable-sized-type-not-at-end
4074------------------------------------
4075This diagnostic is enabled by default.
4076
4077**Diagnostic text:**
4078
4079+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4080|:warning:`warning:` |nbsp| :diagtext:`field` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with variable sized type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`not at the end of a struct or class is a GNU extension`|
4081+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4082
4083
4084-Wgnu-zero-line-directive
4085-------------------------
4086**Diagnostic text:**
4087
4088+--------------------------------------------------------------------------------------------+
4089|:warning:`warning:` |nbsp| :diagtext:`#line directive with zero argument is a GNU extension`|
4090+--------------------------------------------------------------------------------------------+
4091
4092
4093-Wgnu-zero-variadic-macro-arguments
4094-----------------------------------
4095**Diagnostic text:**
4096
4097+---------------------------------------------------------------------------------------------------------------+
4098|:warning:`warning:` |nbsp| :diagtext:`must specify at least one argument for '...' parameter of variadic macro`|
4099+---------------------------------------------------------------------------------------------------------------+
4100
4101+---------------------------------------------------------------------------------------------------+
4102|:warning:`warning:` |nbsp| :diagtext:`token pasting of ',' and \_\_VA\_ARGS\_\_ is a GNU extension`|
4103+---------------------------------------------------------------------------------------------------+
4104
4105
4106-Wheader-guard
4107--------------
4108This diagnostic is enabled by default.
4109
4110**Diagnostic text:**
4111
4112+---------------------------------------------------------------------------------------------------------------------------------------+
4113|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is used as a header guard here, followed by #define of a different macro`|
4114+---------------------------------------------------------------------------------------------------------------------------------------+
4115
4116
4117-Wheader-hygiene
4118----------------
4119**Diagnostic text:**
4120
4121+--------------------------------------------------------------------------------------------+
4122|:warning:`warning:` |nbsp| :diagtext:`using namespace directive in global context in header`|
4123+--------------------------------------------------------------------------------------------+
4124
4125
4126-Widiomatic-parentheses
4127-----------------------
4128**Diagnostic text:**
4129
4130+-----------------------------------------------------------------------------------------------------------+
4131|:warning:`warning:` |nbsp| :diagtext:`using the result of an assignment as a condition without parentheses`|
4132+-----------------------------------------------------------------------------------------------------------+
4133
4134
4135-Wignored-attributes
4136--------------------
4137This diagnostic is enabled by default.
4138
4139**Diagnostic text:**
4140
4141+---------------------------+-------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4142|:warning:`warning:` |nbsp| |+-----------------+| |nbsp| :diagtext:`will always resolve to` |nbsp| :placeholder:`A` |nbsp| :diagtext:`even if weak definition of` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is overridden`|
4143| ||:diagtext:`alias`|| |
4144| |+-----------------+| |
4145| ||:diagtext:`ifunc`|| |
4146| |+-----------------+| |
4147+---------------------------+-------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4148
4149+---------------------------+-------------------+----------------------------------------------------------------------------------------------------------------+----------------------+
4150|:warning:`warning:` |nbsp| |+-----------------+| |nbsp| :diagtext:`will not be in section '`:placeholder:`A`:diagtext:`' but in the same section as the` |nbsp| |+--------------------+|
4151| ||:diagtext:`alias`|| ||:diagtext:`aliasee` ||
4152| |+-----------------+| |+--------------------+|
4153| ||:diagtext:`ifunc`|| ||:diagtext:`resolver`||
4154| |+-----------------+| |+--------------------+|
4155+---------------------------+-------------------+----------------------------------------------------------------------------------------------------------------+----------------------+
4156
4157+----------------------------------------------------------------------+------------------------+-------------------------------------+
4158|:warning:`warning:` |nbsp| :diagtext:`'abi\_tag' attribute on` |nbsp| |+----------------------+| |nbsp| :diagtext:`namespace ignored`|
4159| ||:diagtext:`non-inline`|| |
4160| |+----------------------+| |
4161| ||:diagtext:`anonymous` || |
4162| |+----------------------+| |
4163+----------------------------------------------------------------------+------------------------+-------------------------------------+
4164
4165+-----------------------------------------------------------------------------------------------------------------------+
4166|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`after definition is ignored`|
4167+-----------------------------------------------------------------------------------------------------------------------+
4168
4169+--------------------------------------------------------------------------------------------------------------------------------+
4170|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute can only be applied to instance variables or properties`|
4171+--------------------------------------------------------------------------------------------------------------------------------+
4172
4173+--------------------------------------------------------------------------------+
4174|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute ignored`|
4175+--------------------------------------------------------------------------------+
4176
4177+---------------------------------------------------------------------------------------------------+
4178|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute ignored on inline function`|
4179+---------------------------------------------------------------------------------------------------+
4180
4181+-------------------------------------------------------------------------------------------------------------------+
4182|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' attribute cannot be specified on a definition`|
4183+-------------------------------------------------------------------------------------------------------------------+
4184
4185+------------------------------------------------------------------------------------------------------------------------------------------------+
4186|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored, because it is not attached to a declaration`|
4187+------------------------------------------------------------------------------------------------------------------------------------------------+
4188
4189+--------------------------------------------------------------------------------------------------------+
4190|:warning:`warning:` |nbsp| :diagtext:`'nonnull' attribute applied to function with no pointer arguments`|
4191+--------------------------------------------------------------------------------------------------------+
4192
4193+-----------------------------------------------------------------------------------------------------+
4194|:warning:`warning:` |nbsp| :diagtext:`'nonnull' attribute when used on parameters takes no arguments`|
4195+-----------------------------------------------------------------------------------------------------+
4196
4197+--------------------------------------------------------------------------------------------------+
4198|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute ignored when parsing type`|
4199+--------------------------------------------------------------------------------------------------+
4200
4201+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
4202|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to a pointer or reference (`:placeholder:`B` |nbsp| :diagtext:`is invalid)`|
4203+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
4204
4205+----------------------------------------------------------------------------------------+------------------------------+-------------------------------------+
4206|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to`|+----------------------------+| |nbsp| :diagtext:`pointer arguments`|
4207| || || |
4208| |+----------------------------+| |
4209| || |nbsp| :diagtext:`constant`|| |
4210| |+----------------------------+| |
4211+----------------------------------------------------------------------------------------+------------------------------+-------------------------------------+
4212
4213+------------------------------------------------------------------------------------+
4214|:warning:`warning:` |nbsp| :diagtext:`attribute declaration must precede definition`|
4215+------------------------------------------------------------------------------------+
4216
4217+------------------------------------------------------------------------------------------------------------------------+
4218|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to return values that are pointers`|
4219+------------------------------------------------------------------------------------------------------------------------+
4220
4221+--------------------------------------------------------------------------------------------------------------------------------------+
4222|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to return values that are pointers or references`|
4223+--------------------------------------------------------------------------------------------------------------------------------------+
4224
4225+------------------------------------------------------------------------------------+
4226|:warning:`warning:` |nbsp| :diagtext:`'sentinel' attribute requires named arguments`|
4227+------------------------------------------------------------------------------------+
4228
4229+-----------------------------------------------------------------------------------------------+-----------------------+
4230|:warning:`warning:` |nbsp| :diagtext:`'sentinel' attribute only supported for variadic` |nbsp| |+---------------------+|
4231| ||:diagtext:`functions`||
4232| |+---------------------+|
4233| ||:diagtext:`blocks` ||
4234| |+---------------------+|
4235+-----------------------------------------------------------------------------------------------+-----------------------+
4236
4237+------------------------------------------------------------------------------------------------------------------------+
4238|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute argument not supported:` |nbsp| :placeholder:`B`|
4239+------------------------------------------------------------------------------------------------------------------------+
4240
4241+---------------------------------------------------------------------------------+
4242|:warning:`warning:` |nbsp| :diagtext:`unknown visibility` |nbsp| :placeholder:`A`|
4243+---------------------------------------------------------------------------------+
4244
4245+------------------------------------------------------------------------------------------------------------------------+--------------------------------+----------------------------------------+
4246|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be applied to` |nbsp| |+------------------------------+| |nbsp| :diagtext:`without return value`|
4247| ||:diagtext:`functions` || |
4248| |+------------------------------+| |
4249| ||:diagtext:`Objective-C method`|| |
4250| |+------------------------------+| |
4251+------------------------------------------------------------------------------------------------------------------------+--------------------------------+----------------------------------------+
4252
4253+----------------------------------------------------------------------------------------------------+
4254|:warning:`warning:` |nbsp| :diagtext:`\_\_weak attribute cannot be specified on a field declaration`|
4255+----------------------------------------------------------------------------------------------------+
4256
4257+------------------------------------------------------------------------------------------------------------------------------+
4258|:warning:`warning:` |nbsp| :diagtext:`\_\_weak attribute cannot be specified on an automatic variable when ARC is not enabled`|
4259+------------------------------------------------------------------------------------------------------------------------------+
4260
4261+------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------+
4262|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to` |nbsp| |+----------------------------------------------------------------------------------------------------------------+|
4263| ||:diagtext:`functions` ||
4264| |+----------------------------------------------------------------------------------------------------------------+|
4265| ||:diagtext:`unions` ||
4266| |+----------------------------------------------------------------------------------------------------------------+|
4267| ||:diagtext:`variables and functions` ||
4268| |+----------------------------------------------------------------------------------------------------------------+|
4269| ||:diagtext:`functions, variables, and Objective-C interfaces` ||
4270| |+----------------------------------------------------------------------------------------------------------------+|
4271| ||:diagtext:`functions and methods` ||
4272| |+----------------------------------------------------------------------------------------------------------------+|
4273| ||:diagtext:`parameters` ||
4274| |+----------------------------------------------------------------------------------------------------------------+|
4275| ||:diagtext:`functions, methods and blocks` ||
4276| |+----------------------------------------------------------------------------------------------------------------+|
4277| ||:diagtext:`functions, methods, and classes` ||
4278| |+----------------------------------------------------------------------------------------------------------------+|
4279| ||:diagtext:`functions, methods, and parameters` ||
4280| |+----------------------------------------------------------------------------------------------------------------+|
4281| ||:diagtext:`classes` ||
4282| |+----------------------------------------------------------------------------------------------------------------+|
4283| ||:diagtext:`enums` ||
4284| |+----------------------------------------------------------------------------------------------------------------+|
4285| ||:diagtext:`variables` ||
4286| |+----------------------------------------------------------------------------------------------------------------+|
4287| ||:diagtext:`methods` ||
4288| |+----------------------------------------------------------------------------------------------------------------+|
4289| ||:diagtext:`fields and global variables` ||
4290| |+----------------------------------------------------------------------------------------------------------------+|
4291| ||:diagtext:`structs` ||
4292| |+----------------------------------------------------------------------------------------------------------------+|
4293| ||:diagtext:`parameters and typedefs` ||
4294| |+----------------------------------------------------------------------------------------------------------------+|
4295| ||:diagtext:`variables and typedefs` ||
4296| |+----------------------------------------------------------------------------------------------------------------+|
4297| ||:diagtext:`thread-local variables` ||
4298| |+----------------------------------------------------------------------------------------------------------------+|
4299| ||:diagtext:`variables and fields` ||
4300| |+----------------------------------------------------------------------------------------------------------------+|
4301| ||:diagtext:`variables, data members and tag types` ||
4302| |+----------------------------------------------------------------------------------------------------------------+|
4303| ||:diagtext:`types and namespaces` ||
4304| |+----------------------------------------------------------------------------------------------------------------+|
4305| ||:diagtext:`Objective-C interfaces` ||
4306| |+----------------------------------------------------------------------------------------------------------------+|
4307| ||:diagtext:`methods and properties` ||
4308| |+----------------------------------------------------------------------------------------------------------------+|
4309| ||:diagtext:`struct or union` ||
4310| |+----------------------------------------------------------------------------------------------------------------+|
4311| ||:diagtext:`struct, union or class` ||
4312| |+----------------------------------------------------------------------------------------------------------------+|
4313| ||:diagtext:`types` ||
4314| |+----------------------------------------------------------------------------------------------------------------+|
4315| ||:diagtext:`Objective-C instance methods` ||
4316| |+----------------------------------------------------------------------------------------------------------------+|
4317| ||:diagtext:`init methods of interface or class extension declarations` ||
4318| |+----------------------------------------------------------------------------------------------------------------+|
4319| ||:diagtext:`variables, functions and classes` ||
4320| |+----------------------------------------------------------------------------------------------------------------+|
4321| ||:diagtext:`functions, variables, classes, and Objective-C interfaces` ||
4322| |+----------------------------------------------------------------------------------------------------------------+|
4323| ||:diagtext:`Objective-C protocols` ||
4324| |+----------------------------------------------------------------------------------------------------------------+|
Richard Smithce9d5862016-09-14 01:51:10 +00004325| ||:diagtext:`variables with static or thread storage duration` ||
4326| |+----------------------------------------------------------------------------------------------------------------+|
Richard Smithb6a3b4b2016-09-12 05:58:29 +00004327| ||:diagtext:`functions and global variables` ||
4328| |+----------------------------------------------------------------------------------------------------------------+|
4329| ||:diagtext:`structs, unions, and typedefs` ||
4330| |+----------------------------------------------------------------------------------------------------------------+|
4331| ||:diagtext:`structs and typedefs` ||
4332| |+----------------------------------------------------------------------------------------------------------------+|
4333| ||:diagtext:`interface or protocol declarations` ||
4334| |+----------------------------------------------------------------------------------------------------------------+|
4335| ||:diagtext:`kernel functions` ||
4336| |+----------------------------------------------------------------------------------------------------------------+|
4337| ||:diagtext:`non-K&R-style functions` ||
4338| |+----------------------------------------------------------------------------------------------------------------+|
4339| ||:diagtext:`variables, enums, fields and typedefs` ||
4340| |+----------------------------------------------------------------------------------------------------------------+|
4341| ||:diagtext:`functions, methods, enums, and classes` ||
4342| |+----------------------------------------------------------------------------------------------------------------+|
4343| ||:diagtext:`structs, classes, variables, functions, and inline namespaces` ||
4344| |+----------------------------------------------------------------------------------------------------------------+|
4345| ||:diagtext:`variables, functions, methods, types, enumerations, enumerators, labels, and non-static data members`||
4346| |+----------------------------------------------------------------------------------------------------------------+|
4347+------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------+
4348
4349+--------------------------------------------------------------------------------------------------------------------------------------------------------+
4350|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored, because it cannot be applied to omitted return type`|
4351+--------------------------------------------------------------------------------------------------------------------------------------------------------+
4352
4353+----------------------------------------------------------------------------------------------------------------------------+
4354|:warning:`warning:` |nbsp| :diagtext:`calling convention` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored for this target`|
4355+----------------------------------------------------------------------------------------------------------------------------+
4356
4357+-------------------------------------------------------------------------------------------------------------------+
4358|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`calling convention ignored on constructor/destructor`|
4359+-------------------------------------------------------------------------------------------------------------------+
4360
4361+--------------------------------------------------------------------------------------------------------------+
4362|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`calling convention ignored on variadic function`|
4363+--------------------------------------------------------------------------------------------------------------+
4364
4365+-------------------------------------------------------------------------------------------------------------------------------------------+
4366|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored, because it cannot be applied to a type`|
4367+-------------------------------------------------------------------------------------------------------------------------------------------+
4368
4369+------------------------------------------------------------------------------------------------------------------------+-----------------------+----------------------------------------------------+
4370|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is ignored, place it after "`|+---------------------+|:diagtext:`" to apply attribute to type declaration`|
4371| ||:diagtext:`class` || |
4372| |+---------------------+| |
4373| ||:diagtext:`struct` || |
4374| |+---------------------+| |
4375| ||:diagtext:`interface`|| |
4376| |+---------------------+| |
4377| ||:diagtext:`union` || |
4378| |+---------------------+| |
4379| ||:diagtext:`enum` || |
4380| |+---------------------+| |
4381+------------------------------------------------------------------------------------------------------------------------+-----------------------+----------------------------------------------------+
4382
4383+--------------------------------------------------------------------------------------------+
4384|:warning:`warning:` |nbsp| :diagtext:`'deprecated' attribute on anonymous namespace ignored`|
4385+--------------------------------------------------------------------------------------------+
4386
4387+----------------------------------------------------------------------------------------------------------------------------------------------+
4388|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`redeclared inline;` |nbsp| :placeholder:`B` |nbsp| :diagtext:`attribute ignored`|
4389+----------------------------------------------------------------------------------------------------------------------------------------------+
4390
4391+----------------------------------------------------------------------------------------------------------------------------------------+
4392|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is already applied with different parameters`|
4393+----------------------------------------------------------------------------------------------------------------------------------------+
4394
4395+--------------------------------------------------------------------------------------------------------------+
4396|:warning:`warning:` |nbsp| :diagtext:`attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is already applied`|
4397+--------------------------------------------------------------------------------------------------------------+
4398
4399+------------------------------------------------------------------------------------------------+
4400|:warning:`warning:` |nbsp| :diagtext:`Objective-C GC does not allow weak variables on the stack`|
4401+------------------------------------------------------------------------------------------------+
4402
4403+-------------------------------------------------------------------------------------------------------------------------+
4404|:warning:`warning:` |nbsp| :diagtext:`'gnu\_inline' attribute requires function to be marked 'inline', attribute ignored`|
4405+-------------------------------------------------------------------------------------------------------------------------+
4406
4407+---------------------------------------------------------------------------+------------------------------------+
4408|:warning:`warning:` |nbsp| :diagtext:`inheritance model ignored on` |nbsp| |+----------------------------------+|
4409| ||:diagtext:`primary template` ||
4410| |+----------------------------------+|
4411| ||:diagtext:`partial specialization`||
4412| |+----------------------------------+|
4413+---------------------------------------------------------------------------+------------------------------------+
4414
4415+--------------------------------------------------------------------------------------------------------------+
4416|:warning:`warning:` |nbsp| :diagtext:`'internal\_linkage' attribute on a non-static local variable is ignored`|
4417+--------------------------------------------------------------------------------------------------------------+
4418
4419+--------------------------------------------------------------------------------------------+
4420|:warning:`warning:` |nbsp| :diagtext:`qualifiers after comma in declarator list are ignored`|
4421+--------------------------------------------------------------------------------------------+
4422
4423+-------------------------------------------------------------------------------------------------------------+----------------------------------+
4424|:warning:`warning:` |nbsp| :diagtext:`MIPS 'interrupt' attribute only applies to functions that have` |nbsp| |+--------------------------------+|
4425| ||:diagtext:`no parameters` ||
4426| |+--------------------------------+|
4427| ||:diagtext:`a 'void' return type`||
4428| |+--------------------------------+|
4429+-------------------------------------------------------------------------------------------------------------+----------------------------------+
4430
4431+---------------------------------------------------------------------------------------+
4432|:warning:`warning:` |nbsp| :diagtext:`unknown attribute '`:placeholder:`A`:diagtext:`'`|
4433+---------------------------------------------------------------------------------------+
4434
4435+------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------+
4436|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to` |nbsp| |+---------------------------------+| |nbsp| :diagtext:`parameters`|
4437| ||:diagtext:`Objective-C object` || |
4438| |+---------------------------------+| |
4439| ||:diagtext:`pointer` || |
4440| |+---------------------------------+| |
4441| ||:diagtext:`pointer-to-CF-pointer`|| |
4442| |+---------------------------------+| |
4443+------------------------------------------------------------------------------------------------+-----------------------------------+------------------------------+
4444
4445+------------------------------------------------------------------------------------------------+------------------------+---------------------------------------+--------------------------------------+
4446|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute only applies to` |nbsp| |+----------------------+| |nbsp| :diagtext:`that return` |nbsp| |+------------------------------------+|
4447| ||:diagtext:`functions` || ||:diagtext:`an Objective-C object` ||
4448| |+----------------------+| |+------------------------------------+|
4449| ||:diagtext:`methods` || ||:diagtext:`a pointer` ||
4450| |+----------------------+| |+------------------------------------+|
4451| ||:diagtext:`properties`|| ||:diagtext:`a non-retainable pointer`||
4452| |+----------------------+| |+------------------------------------+|
4453+------------------------------------------------------------------------------------------------+------------------------+---------------------------------------+--------------------------------------+
4454
4455+--------------------------------------------------------------------------------------------------------------------------------------------+
4456|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute is deprecated and ignored in OpenCL version` |nbsp| :placeholder:`B`|
4457+--------------------------------------------------------------------------------------------------------------------------------------------+
4458
4459+---------------------------+-----------------------+---------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+-------------------------------------------------------------------------------------------------+
4460|:warning:`warning:` |nbsp| |+---------------------+| |nbsp| :diagtext:`of field` |nbsp| :placeholder:`B` |nbsp| :diagtext:`(`:placeholder:`C` |nbsp| :diagtext:`bits) does not match the` |nbsp| |+---------------------+| |nbsp| :diagtext:`of the first field in transparent union; transparent\_union attribute ignored`|
4461| ||:diagtext:`alignment`|| ||:diagtext:`alignment`|| |
4462| |+---------------------+| |+---------------------+| |
4463| ||:diagtext:`size` || ||:diagtext:`size` || |
4464| |+---------------------+| |+---------------------+| |
4465+---------------------------+-----------------------+---------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+-------------------------------------------------------------------------------------------------+
4466
4467+---------------------------------------------------------------------------------------------+----------------------------+--------------------------------------------------------------------------------------------------+
4468|:warning:`warning:` |nbsp| :diagtext:`first field of a transparent union cannot have` |nbsp| |+--------------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`B`:diagtext:`; transparent\_union attribute ignored`|
4469| ||:diagtext:`floating point`|| |
4470| |+--------------------------+| |
4471| ||:diagtext:`vector` || |
4472| |+--------------------------+| |
4473+---------------------------------------------------------------------------------------------+----------------------------+--------------------------------------------------------------------------------------------------+
4474
4475+--------------------------------------------------------------------------------------------------------------------------------+
4476|:warning:`warning:` |nbsp| :diagtext:`transparent\_union attribute can only be applied to a union definition; attribute ignored`|
4477+--------------------------------------------------------------------------------------------------------------------------------+
4478
4479+-----------------------------------------------------------------------------------------------------------------------------------------+
4480|:warning:`warning:` |nbsp| :diagtext:`transparent union definition must contain at least one field; transparent\_union attribute ignored`|
4481+-----------------------------------------------------------------------------------------------------------------------------------------+
4482
4483+---------------------------------------------------------------------------------------------+-------------------------------------------------+---------------------------------------------------------------+
4484|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' only applies to` |nbsp| |+-----------------------------------------------+| |nbsp| :diagtext:`types; type here is` |nbsp| :placeholder:`C`|
4485| ||:diagtext:`function` || |
4486| |+-----------------------------------------------+| |
4487| ||:diagtext:`pointer` || |
4488| |+-----------------------------------------------+| |
4489| ||:diagtext:`Objective-C object or block pointer`|| |
4490| |+-----------------------------------------------+| |
4491+---------------------------------------------------------------------------------------------+-------------------------------------------------+---------------------------------------------------------------+
4492
4493+-------------------------------------------------------------------------------------------------------------------------+
4494|:warning:`warning:` |nbsp| :diagtext:`\_\_declspec attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not supported`|
4495+-------------------------------------------------------------------------------------------------------------------------+
4496
4497+-------------------------------------------------------------------------------------------------------------------------+
4498|:warning:`warning:` |nbsp| :diagtext:`Ignoring unsupported '`:placeholder:`A`:diagtext:`' in the target attribute string`|
4499+-------------------------------------------------------------------------------------------------------------------------+
4500
4501
4502-Wignored-optimization-argument
4503-------------------------------
4504This diagnostic is enabled by default.
4505
4506**Diagnostic text:**
4507
4508+--------------------------------------------------------------------------------------------------------------------------------------------------+
4509|:warning:`warning:` |nbsp| :diagtext:`optimization flag '`:placeholder:`A`:diagtext:`' is not supported for target '`:placeholder:`B`:diagtext:`'`|
4510+--------------------------------------------------------------------------------------------------------------------------------------------------+
4511
4512+--------------------------------------------------------------------------------------------------------+
4513|:warning:`warning:` |nbsp| :diagtext:`optimization flag '`:placeholder:`A`:diagtext:`' is not supported`|
4514+--------------------------------------------------------------------------------------------------------+
4515
4516
4517-Wignored-pragmas
4518-----------------
4519This diagnostic is enabled by default.
4520
4521**Diagnostic text:**
4522
4523+------------------------------------------------------------------------------+---------------------------+-----------------------+
4524|:warning:`warning:` |nbsp| :diagtext:`expected '=' following '#pragma` |nbsp| |+-------------------------+|:diagtext:`' - ignored`|
4525| ||:diagtext:`align` || |
4526| |+-------------------------+| |
4527| ||:diagtext:`options align`|| |
4528| |+-------------------------+| |
4529+------------------------------------------------------------------------------+---------------------------+-----------------------+
4530
4531+-----------------------------------------------------------------------------------+---------------------------+-----------------------+
4532|:warning:`warning:` |nbsp| :diagtext:`invalid alignment option in '#pragma` |nbsp| |+-------------------------+|:diagtext:`' - ignored`|
4533| ||:diagtext:`align` || |
4534| |+-------------------------+| |
4535| ||:diagtext:`options align`|| |
4536| |+-------------------------+| |
4537+-----------------------------------------------------------------------------------+---------------------------+-----------------------+
4538
4539+----------------------------------------------------------------------------------------------------+
4540|:warning:`warning:` |nbsp| :diagtext:`'#pragma comment` |nbsp| :placeholder:`A`:diagtext:`' ignored`|
4541+----------------------------------------------------------------------------------------------------+
4542
4543+-------------------------------------------------------------------------------------------------------+
4544|:warning:`warning:` |nbsp| :diagtext:`missing argument to debug command '`:placeholder:`A`:diagtext:`'`|
4545+-------------------------------------------------------------------------------------------------------+
4546
4547+----------------------------------------------------------------------------------------------+
4548|:warning:`warning:` |nbsp| :diagtext:`unexpected debug command '`:placeholder:`A`:diagtext:`'`|
4549+----------------------------------------------------------------------------------------------+
4550
4551+------------------------------------------------------------------------------------------------------------------------+
4552|:warning:`warning:` |nbsp| :diagtext:`expected action or ')' in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4553+------------------------------------------------------------------------------------------------------------------------+
4554
4555+--------------------------------------------------------------------------------------------------------------+
4556|:warning:`warning:` |nbsp| :diagtext:`missing ':' after` |nbsp| :placeholder:`A` |nbsp| :diagtext:`- ignoring`|
4557+--------------------------------------------------------------------------------------------------------------+
4558
4559+---------------------------------------------------------------------------------------------------------------------+
4560|:warning:`warning:` |nbsp| :diagtext:`missing ':' or ')' after` |nbsp| :placeholder:`A` |nbsp| :diagtext:`- ignoring`|
4561+---------------------------------------------------------------------------------------------------------------------+
4562
4563+--------------------------------------------------------------------------------+
4564|:warning:`warning:` |nbsp| :diagtext:`expected 'enable' or 'disable' - ignoring`|
4565+--------------------------------------------------------------------------------+
4566
4567+---------------------------------------------------------------------------------------------------------------------+
4568|:warning:`warning:` |nbsp| :diagtext:`expected identifier in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4569+---------------------------------------------------------------------------------------------------------------------+
4570
4571+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4572|:warning:`warning:` |nbsp| :diagtext:`expected 'compiler', 'lib', 'user', or a string literal for the section name in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4573+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4574
4575+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4576|:warning:`warning:` |nbsp| :diagtext:`expected integer between` |nbsp| :placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B` |nbsp| :diagtext:`inclusive in '#pragma` |nbsp| :placeholder:`C`:diagtext:`' - ignored`|
4577+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4578
4579+-----------------------------------------------------------------------------------------------------------------+
4580|:warning:`warning:` |nbsp| :diagtext:`missing '(' after '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignoring`|
4581+-----------------------------------------------------------------------------------------------------------------+
4582
4583+------------------------------------------------------------------------------------------------------------------------+
4584|:warning:`warning:` |nbsp| :diagtext:`expected non-wide string literal in '#pragma` |nbsp| :placeholder:`A`:diagtext:`'`|
4585+------------------------------------------------------------------------------------------------------------------------+
4586
4587+-----------------------------------------------------------------------------------------------------------+
4588|:warning:`warning:` |nbsp| :diagtext:`expected ')' or ',' in '#pragma` |nbsp| :placeholder:`A`:diagtext:`'`|
4589+-----------------------------------------------------------------------------------------------------------+
4590
4591+-----------------------------------------------------------------------------------------------------------------+
4592|:warning:`warning:` |nbsp| :diagtext:`missing ')' after '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignoring`|
4593+-----------------------------------------------------------------------------------------------------------------+
4594
4595+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
4596|:warning:`warning:` |nbsp| :diagtext:`expected a stack label or a string literal for the section name in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4597+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
4598
4599+------------------------------------------------------------------------------------------------------------------------------------------------+
4600|:warning:`warning:` |nbsp| :diagtext:`expected a string literal for the section name in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4601+------------------------------------------------------------------------------------------------------------------------------------------------+
4602
4603+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
4604|:warning:`warning:` |nbsp| :diagtext:`expected push, pop or a string literal for the section name in '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4605+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
4606
4607+---------------------------------------------------------------------------------------------------------------------+
4608|:warning:`warning:` |nbsp| :diagtext:`extra tokens at end of '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4609+---------------------------------------------------------------------------------------------------------------------+
4610
4611+-------------------------------------------------------------------------------------------------------------------+
4612|:warning:`warning:` |nbsp| :diagtext:`'#pragma init\_seg' is only supported when targeting a Microsoft environment`|
4613+-------------------------------------------------------------------------------------------------------------------+
4614
Richard Smithce9d5862016-09-14 01:51:10 +00004615+------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+
4616|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not a recognized builtin`|+----------------------------------------------------------------------------+|
4617| || ||
4618| |+----------------------------------------------------------------------------+|
4619| ||:diagtext:`; consider including <intrin.h> to access non-builtin intrinsics`||
4620| |+----------------------------------------------------------------------------+|
4621+------------------------------------------------------------------------------------------+------------------------------------------------------------------------------+
4622
Richard Smithb6a3b4b2016-09-12 05:58:29 +00004623+-----------------------------------------------------------------------------------------------------------------+
4624|:warning:`warning:` |nbsp| :diagtext:`unknown action for '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4625+-----------------------------------------------------------------------------------------------------------------+
4626
4627+------------------------------------------------------------------------------------------------------------------------------------------------+
4628|:warning:`warning:` |nbsp| :diagtext:`unknown action '`:placeholder:`B`:diagtext:`' for '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4629+------------------------------------------------------------------------------------------------------------------------------------------------+
4630
4631+----------------------------------------------------------------------------------------------+
4632|:warning:`warning:` |nbsp| :diagtext:`incorrect use of '#pragma ms\_struct on\|off' - ignored`|
4633+----------------------------------------------------------------------------------------------+
4634
4635+--------------------------------------------------------------------------------------------------+
4636|:warning:`warning:` |nbsp| :diagtext:`#pragma options align=reset failed:` |nbsp| :placeholder:`A`|
4637+--------------------------------------------------------------------------------------------------+
4638
4639+---------------------------------------------------------------------------------------------+
4640|:warning:`warning:` |nbsp| :diagtext:`expected 'align' following '#pragma options' - ignored`|
4641+---------------------------------------------------------------------------------------------+
4642
4643+--------------------------------------------------------------------------------------------------------+
4644|:warning:`warning:` |nbsp| :diagtext:`expected #pragma pack parameter to be '1', '2', '4', '8', or '16'`|
4645+--------------------------------------------------------------------------------------------------------+
4646
4647+-------------------------------------------------------------------------------------------------+
4648|:warning:`warning:` |nbsp| :diagtext:`expected integer or identifier in '#pragma pack' - ignored`|
4649+-------------------------------------------------------------------------------------------------+
4650
4651+----------------------------------------------------------------------------------------------------------------------------+
4652|:warning:`warning:` |nbsp| :diagtext:`#pragma` |nbsp| :placeholder:`A`:diagtext:`(pop, ...) failed:` |nbsp| :placeholder:`B`|
4653+----------------------------------------------------------------------------------------------------------------------------+
4654
4655+------------------------------------------------------------------------------------------------------------------------------+
4656|:warning:`warning:` |nbsp| :diagtext:`pragma pop\_macro could not pop '`:placeholder:`A`:diagtext:`', no matching push\_macro`|
4657+------------------------------------------------------------------------------------------------------------------------------+
4658
4659+---------------------------------------------------------------------------------------------------------------------+
4660|:warning:`warning:` |nbsp| :diagtext:`unknown OpenCL extension` |nbsp| :placeholder:`A` |nbsp| :diagtext:`- ignoring`|
4661+---------------------------------------------------------------------------------------------------------------------+
4662
4663+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
4664|:warning:`warning:` |nbsp| :diagtext:`known but unsupported action '`:placeholder:`B`:diagtext:`' for '#pragma` |nbsp| :placeholder:`A`:diagtext:`' - ignored`|
4665+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
4666
4667+-------------------------------------------------------------------------------------------------------------------------+
4668|:warning:`warning:` |nbsp| :diagtext:`unsupported OpenCL extension` |nbsp| :placeholder:`A` |nbsp| :diagtext:`- ignoring`|
4669+-------------------------------------------------------------------------------------------------------------------------+
4670
4671+-----------------------------------------------------------------------------------------------+
4672|:warning:`warning:` |nbsp| :diagtext:`expected '#pragma unused' argument to be a variable name`|
4673+-----------------------------------------------------------------------------------------------+
4674
4675+------------------------------------------------------------------------------------------+
4676|:warning:`warning:` |nbsp| :diagtext:`only variables can be arguments to '#pragma unused'`|
4677+------------------------------------------------------------------------------------------+
4678
4679+----------------------------------------------------------------------------------------------------------------------------------------------+
4680|:warning:`warning:` |nbsp| :diagtext:`undeclared variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`used as an argument for '#pragma unused'`|
4681+----------------------------------------------------------------------------------------------------------------------------------------------+
4682
4683
4684-Wignored-qualifiers
4685--------------------
4686Some of the diagnostics controlled by this flag are enabled by default.
4687
4688**Diagnostic text:**
4689
4690+--------------------------------------------------+------------------------------------+----------------------------------------------------------------+
4691|:warning:`warning:` |nbsp| :diagtext:`ARC` |nbsp| |+----------------------------------+| |nbsp| :diagtext:`lifetime qualifier on return type is ignored`|
4692| ||:diagtext:`unused` || |
4693| |+----------------------------------+| |
4694| ||:diagtext:`\_\_unsafe\_unretained`|| |
4695| |+----------------------------------+| |
4696| ||:diagtext:`\_\_strong` || |
4697| |+----------------------------------+| |
4698| ||:diagtext:`\_\_weak` || |
4699| |+----------------------------------+| |
4700| ||:diagtext:`\_\_autoreleasing` || |
4701| |+----------------------------------+| |
4702+--------------------------------------------------+------------------------------------+----------------------------------------------------------------+
4703
4704+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
4705|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' qualifier on omitted return type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`has no effect`|
4706+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
4707
4708+------------------------------------------------------------------------------------+---------------+------------------------------------------+-------------------+-----------------------------+
4709|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' type qualifier`|+-------------+| |nbsp| :diagtext:`on return type` |nbsp| |+-----------------+| |nbsp| :diagtext:`no effect`|
4710| || || ||:diagtext:`:has` || |
4711| |+-------------+| |+-----------------+| |
4712| ||:diagtext:`s`|| ||:diagtext:`:have`|| |
4713| |+-------------+| |+-----------------+| |
4714+------------------------------------------------------------------------------------+---------------+------------------------------------------+-------------------+-----------------------------+
4715
4716+---------------------------------------------------------------------------------------------------------------------------------------------------------+
4717|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' qualifier on function type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`has no effect`|
4718+---------------------------------------------------------------------------------------------------------------------------------------------------------+
4719
4720+----------------------------------------------------------------------------------------------------------------------------------------------------------+
4721|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' qualifier on reference type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`has no effect`|
4722+----------------------------------------------------------------------------------------------------------------------------------------------------------+
4723
4724
4725-Wimplicit
4726----------
4727Some of the diagnostics controlled by this flag are enabled by default.
4728
4729Controls `-Wimplicit-function-declaration`_, `-Wimplicit-int`_.
4730
4731
4732-Wimplicit-atomic-properties
4733----------------------------
4734**Diagnostic text:**
4735
4736+-----------------------------------------------------------------------------------------------------+
4737|:warning:`warning:` |nbsp| :diagtext:`property is assumed atomic when auto-synthesizing the property`|
4738+-----------------------------------------------------------------------------------------------------+
4739
4740+----------------------------------------------------------------------------+
4741|:warning:`warning:` |nbsp| :diagtext:`property is assumed atomic by default`|
4742+----------------------------------------------------------------------------+
4743
4744
4745-Wimplicit-conversion-floating-point-to-bool
4746--------------------------------------------
4747This diagnostic is enabled by default.
4748
4749**Diagnostic text:**
4750
4751+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4752|:warning:`warning:` |nbsp| :diagtext:`implicit conversion turns floating-point number into bool:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
4753+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
4754
4755
4756-Wimplicit-exception-spec-mismatch
4757----------------------------------
4758This diagnostic is enabled by default.
4759
4760**Diagnostic text:**
4761
4762+-----------------------------------------------------------------------------------+----------------------+----------------------------------------------------------------------+----------------------+-------------------------------------------+
4763|:warning:`warning:` |nbsp| :diagtext:`function previously declared with an` |nbsp| |+--------------------+| |nbsp| :diagtext:`exception specification redeclared with an` |nbsp| |+--------------------+| |nbsp| :diagtext:`exception specification`|
4764| ||:diagtext:`explicit`|| ||:diagtext:`implicit`|| |
4765| |+--------------------+| |+--------------------+| |
4766| ||:diagtext:`implicit`|| ||:diagtext:`explicit`|| |
4767| |+--------------------+| |+--------------------+| |
4768+-----------------------------------------------------------------------------------+----------------------+----------------------------------------------------------------------+----------------------+-------------------------------------------+
4769
4770
4771-Wimplicit-fallthrough
4772----------------------
4773Also controls `-Wimplicit-fallthrough-per-function`_.
4774
4775**Diagnostic text:**
4776
4777+---------------------------------------------------------------------------------+
4778|:warning:`warning:` |nbsp| :diagtext:`fallthrough annotation in unreachable code`|
4779+---------------------------------------------------------------------------------+
4780
4781+-------------------------------------------------------------------------------------+
4782|:warning:`warning:` |nbsp| :diagtext:`unannotated fall-through between switch labels`|
4783+-------------------------------------------------------------------------------------+
4784
4785
4786-Wimplicit-fallthrough-per-function
4787-----------------------------------
4788**Diagnostic text:**
4789
4790+------------------------------------------------------------------------------------------------------------------+
4791|:warning:`warning:` |nbsp| :diagtext:`unannotated fall-through between switch labels in partly-annotated function`|
4792+------------------------------------------------------------------------------------------------------------------+
4793
4794
4795-Wimplicit-function-declaration
4796-------------------------------
4797Some of the diagnostics controlled by this flag are enabled by default.
4798
4799**Diagnostic text:**
4800
4801+------------------------------------------------------------------------------------------------------------------------------------+
4802|:warning:`warning:` |nbsp| :diagtext:`implicit declaration of function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is invalid in C99`|
4803+------------------------------------------------------------------------------------------------------------------------------------+
4804
4805+---------------------------------------------------------------------------------------------------------------------------------------------+
4806|:warning:`warning:` |nbsp| :diagtext:`implicitly declaring library function '`:placeholder:`A`:diagtext:`' with type` |nbsp| :placeholder:`B`|
4807+---------------------------------------------------------------------------------------------------------------------------------------------+
4808
4809+---------------------------------------------------------------------------------+
4810|:error:`error:` |nbsp| :diagtext:`use of unknown builtin` |nbsp| :placeholder:`A`|
4811+---------------------------------------------------------------------------------+
4812
4813+-----------------------------------------------------------------------------------------------+
4814|:warning:`warning:` |nbsp| :diagtext:`implicit declaration of function` |nbsp| :placeholder:`A`|
4815+-----------------------------------------------------------------------------------------------+
4816
4817
4818-Wimplicit-int
4819--------------
4820This diagnostic is enabled by default.
4821
4822**Diagnostic text:**
4823
4824+--------------------------------------------------------------------------------+
4825|:warning:`warning:` |nbsp| :diagtext:`type specifier missing, defaults to 'int'`|
4826+--------------------------------------------------------------------------------+
4827
4828
4829-Wimplicit-retain-self
4830----------------------
4831**Diagnostic text:**
4832
4833+---------------------------------------------------------------------------------------------------------------------------------------+
4834|:warning:`warning:` |nbsp| :diagtext:`block implicitly retains 'self'; explicitly mention 'self' to indicate this is intended behavior`|
4835+---------------------------------------------------------------------------------------------------------------------------------------+
4836
4837
4838-Wimplicitly-unsigned-literal
4839-----------------------------
4840This diagnostic is enabled by default.
4841
4842**Diagnostic text:**
4843
4844+----------------------------------------------------------------------------------------------------------------------------------------+
4845|:warning:`warning:` |nbsp| :diagtext:`integer literal is too large to be represented in a signed integer type, interpreting as unsigned`|
4846+----------------------------------------------------------------------------------------------------------------------------------------+
4847
4848
4849-Wimport
4850--------
4851This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
4852
4853-Wimport-preprocessor-directive-pedantic
4854----------------------------------------
4855**Diagnostic text:**
4856
4857+----------------------------------------------------------------------+
4858|:warning:`warning:` |nbsp| :diagtext:`#import is a language extension`|
4859+----------------------------------------------------------------------+
4860
4861
4862-Winaccessible-base
4863-------------------
4864This diagnostic is enabled by default.
4865
4866**Diagnostic text:**
4867
4868+-----------------------------------------------------------------------------------------------------------------------------------------------+
4869|:warning:`warning:` |nbsp| :diagtext:`direct base` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is inaccessible due to ambiguity:`:placeholder:`B`|
4870+-----------------------------------------------------------------------------------------------------------------------------------------------+
4871
4872
4873-Winclude-next-absolute-path
4874----------------------------
4875This diagnostic is enabled by default.
4876
4877**Diagnostic text:**
4878
4879+------------------------------------------------------------------------+
4880|:warning:`warning:` |nbsp| :diagtext:`#include\_next with absolute path`|
4881+------------------------------------------------------------------------+
4882
4883
4884-Winclude-next-outside-header
4885-----------------------------
4886This diagnostic is enabled by default.
4887
4888**Diagnostic text:**
4889
4890+----------------------------------------------------------------------------+
4891|:warning:`warning:` |nbsp| :diagtext:`#include\_next in primary source file`|
4892+----------------------------------------------------------------------------+
4893
4894
4895-Wincompatible-function-pointer-types
4896-------------------------------------
4897This diagnostic is enabled by default.
4898
4899**Diagnostic text:**
4900
4901+----------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
4902|:warning:`warning:` |nbsp| :diagtext:`incompatible function pointer types` |nbsp| |+--------------------------------------------------------------+|+-------------------------------------+|
4903| ||:diagtext:`assigning to different types` ||| ||
4904| |+--------------------------------------------------------------+|+-------------------------------------+|
4905| ||:diagtext:`passing to parameter of different type` |||:diagtext:`; dereference with \*` ||
4906| |+--------------------------------------------------------------+|+-------------------------------------+|
4907| ||:diagtext:`returning from function with different return type`|||:diagtext:`; take the address with &`||
4908| |+--------------------------------------------------------------+|+-------------------------------------+|
4909| ||:diagtext:`converting between types` |||:diagtext:`; remove \*` ||
4910| |+--------------------------------------------------------------+|+-------------------------------------+|
4911| ||:diagtext:`initializing with expression of different type` |||:diagtext:`; remove &` ||
4912| |+--------------------------------------------------------------+|+-------------------------------------+|
4913| ||:diagtext:`sending to parameter of different type` || |
4914| |+--------------------------------------------------------------+| |
4915| ||:diagtext:`casting between types` || |
4916| |+--------------------------------------------------------------+| |
4917+----------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
4918
4919
4920-Wincompatible-library-redeclaration
4921------------------------------------
4922This diagnostic is enabled by default.
4923
4924**Diagnostic text:**
4925
4926+-------------------------------------------------------------------------------------------------------------+
4927|:warning:`warning:` |nbsp| :diagtext:`incompatible redeclaration of library function` |nbsp| :placeholder:`A`|
4928+-------------------------------------------------------------------------------------------------------------+
4929
4930
4931-Wincompatible-ms-struct
4932------------------------
4933This diagnostic is an error by default, but the flag ``-Wno-incompatible-ms-struct`` can be used to disable the error.
4934
4935**Diagnostic text:**
4936
4937+---------------------------------------------------------------------------------------------------------------------------------------------+
4938|:error:`error:` |nbsp| :diagtext:`ms\_struct may not produce Microsoft-compatible layouts for classes with base classes or virtual functions`|
4939+---------------------------------------------------------------------------------------------------------------------------------------------+
4940
4941
4942-Wincompatible-pointer-types
4943----------------------------
4944This diagnostic is enabled by default.
4945
4946Also controls `-Wincompatible-pointer-types-discards-qualifiers`_, `-Wincompatible-function-pointer-types`_.
4947
4948**Diagnostic text:**
4949
4950+-------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
4951|:warning:`warning:` |nbsp| :diagtext:`incompatible pointer types` |nbsp| |+--------------------------------------------------------------+|+-------------------------------------+|
4952| ||:diagtext:`assigning to different types` ||| ||
4953| |+--------------------------------------------------------------+|+-------------------------------------+|
4954| ||:diagtext:`passing to parameter of different type` |||:diagtext:`; dereference with \*` ||
4955| |+--------------------------------------------------------------+|+-------------------------------------+|
4956| ||:diagtext:`returning from function with different return type`|||:diagtext:`; take the address with &`||
4957| |+--------------------------------------------------------------+|+-------------------------------------+|
4958| ||:diagtext:`converting between types` |||:diagtext:`; remove \*` ||
4959| |+--------------------------------------------------------------+|+-------------------------------------+|
4960| ||:diagtext:`initializing with expression of different type` |||:diagtext:`; remove &` ||
4961| |+--------------------------------------------------------------+|+-------------------------------------+|
4962| ||:diagtext:`sending to parameter of different type` || |
4963| |+--------------------------------------------------------------+| |
4964| ||:diagtext:`casting between types` || |
4965| |+--------------------------------------------------------------+| |
4966+-------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
4967
4968
4969-Wincompatible-pointer-types-discards-qualifiers
4970------------------------------------------------
4971This diagnostic is enabled by default.
4972
4973**Diagnostic text:**
4974
4975+---------------------------+----------------------------------------------------------------+---------------------------------------------------------------+
4976|:warning:`warning:` |nbsp| |+--------------------------------------------------------------+| |nbsp| :diagtext:`discards qualifiers in nested pointer types`|
4977| ||:diagtext:`assigning to different types` || |
4978| |+--------------------------------------------------------------+| |
4979| ||:diagtext:`passing to parameter of different type` || |
4980| |+--------------------------------------------------------------+| |
4981| ||:diagtext:`returning from function with different return type`|| |
4982| |+--------------------------------------------------------------+| |
4983| ||:diagtext:`converting between types` || |
4984| |+--------------------------------------------------------------+| |
4985| ||:diagtext:`initializing with expression of different type` || |
4986| |+--------------------------------------------------------------+| |
4987| ||:diagtext:`sending to parameter of different type` || |
4988| |+--------------------------------------------------------------+| |
4989| ||:diagtext:`casting between types` || |
4990| |+--------------------------------------------------------------+| |
4991+---------------------------+----------------------------------------------------------------+---------------------------------------------------------------+
4992
4993+---------------------------+----------------------------------------------------------------+---------------------------------------+
4994|:warning:`warning:` |nbsp| |+--------------------------------------------------------------+| |nbsp| :diagtext:`discards qualifiers`|
4995| ||:diagtext:`assigning to different types` || |
4996| |+--------------------------------------------------------------+| |
4997| ||:diagtext:`passing to parameter of different type` || |
4998| |+--------------------------------------------------------------+| |
4999| ||:diagtext:`returning from function with different return type`|| |
5000| |+--------------------------------------------------------------+| |
5001| ||:diagtext:`converting between types` || |
5002| |+--------------------------------------------------------------+| |
5003| ||:diagtext:`initializing with expression of different type` || |
5004| |+--------------------------------------------------------------+| |
5005| ||:diagtext:`sending to parameter of different type` || |
5006| |+--------------------------------------------------------------+| |
5007| ||:diagtext:`casting between types` || |
5008| |+--------------------------------------------------------------+| |
5009+---------------------------+----------------------------------------------------------------+---------------------------------------+
5010
5011
5012-Wincompatible-property-type
5013----------------------------
5014This diagnostic is enabled by default.
5015
5016**Diagnostic text:**
5017
5018+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5019|:warning:`warning:` |nbsp| :diagtext:`property type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is incompatible with type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`inherited from` |nbsp| :placeholder:`C`|
5020+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5021
5022
5023-Wincompatible-sysroot
5024----------------------
5025This diagnostic is enabled by default.
5026
5027**Diagnostic text:**
5028
5029+------------------------------------------------------------------------------------------------------------------------------------+
5030|:warning:`warning:` |nbsp| :diagtext:`using sysroot for '`:placeholder:`A`:diagtext:`' but targeting '`:placeholder:`B`:diagtext:`'`|
5031+------------------------------------------------------------------------------------------------------------------------------------+
5032
5033
5034-Wincomplete-implementation
5035---------------------------
5036This diagnostic is enabled by default.
5037
5038**Diagnostic text:**
5039
5040+-----------------------------------------------------------------------------------------------------------------+
5041|:warning:`warning:` |nbsp| :diagtext:`method definition for` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found`|
5042+-----------------------------------------------------------------------------------------------------------------+
5043
5044
5045-Wincomplete-module
5046-------------------
5047Some of the diagnostics controlled by this flag are enabled by default.
5048
5049Controls `-Wincomplete-umbrella`_, `-Wnon-modular-include-in-module`_.
5050
5051
5052-Wincomplete-umbrella
5053---------------------
5054This diagnostic is enabled by default.
5055
5056**Diagnostic text:**
5057
5058+---------------------------------------------------------------------------------------+
5059|:warning:`warning:` |nbsp| :diagtext:`missing submodule '`:placeholder:`A`:diagtext:`'`|
5060+---------------------------------------------------------------------------------------+
5061
5062+-------------------------------------------------------------------------------------------------------------------------------------------------------+
5063|:warning:`warning:` |nbsp| :diagtext:`umbrella header for module '`:placeholder:`A`:diagtext:`' does not include header '`:placeholder:`B`:diagtext:`'`|
5064+-------------------------------------------------------------------------------------------------------------------------------------------------------+
5065
5066
5067-Winconsistent-dllimport
5068------------------------
5069This diagnostic is enabled by default.
5070
5071**Diagnostic text:**
5072
5073+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5074|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`redeclared without` |nbsp| :placeholder:`B` |nbsp| :diagtext:`attribute: previous` |nbsp| :placeholder:`B` |nbsp| :diagtext:`ignored`|
5075+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5076
5077+------------------------------------------------------------------------------------------------------------------------------------+
5078|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`redeclared without 'dllimport' attribute: 'dllexport' attribute added`|
5079+------------------------------------------------------------------------------------------------------------------------------------+
5080
5081
5082-Winconsistent-missing-override
5083-------------------------------
5084This diagnostic is enabled by default.
5085
5086**Diagnostic text:**
5087
5088+-----------------------------------------------------------------------------------------------------------------------+
5089|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`overrides a member function but is not marked 'override'`|
5090+-----------------------------------------------------------------------------------------------------------------------+
5091
5092
5093-Wincrement-bool
5094----------------
5095This diagnostic is enabled by default.
5096
5097Also controls `-Wdeprecated-increment-bool`_.
5098
5099**Diagnostic text:**
5100
5101+------------------------------------------------------------------------------------------------+
5102|:error:`error:` |nbsp| :diagtext:`ISO C++1z does not allow incrementing expression of type bool`|
5103+------------------------------------------------------------------------------------------------+
5104
5105
5106-Winfinite-recursion
5107--------------------
5108**Diagnostic text:**
5109
5110+---------------------------------------------------------------------------------------+
5111|:warning:`warning:` |nbsp| :diagtext:`all paths through this function will call itself`|
5112+---------------------------------------------------------------------------------------+
5113
5114
5115-Winit-self
5116-----------
5117This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
5118
5119-Winitializer-overrides
5120-----------------------
5121This diagnostic is enabled by default.
5122
5123**Diagnostic text:**
5124
5125+---------------------------------------------------------------------------------------------------+
5126|:warning:`warning:` |nbsp| :diagtext:`initializer overrides prior initialization of this subobject`|
5127+---------------------------------------------------------------------------------------------------+
5128
5129+---------------------------------------------------------------------------------------------------------------------------------------+
5130|:warning:`warning:` |nbsp| :diagtext:`subobject initialization overrides initialization of other fields within its enclosing subobject`|
5131+---------------------------------------------------------------------------------------------------------------------------------------+
5132
5133
5134-Winline
5135--------
5136This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
5137
5138-Winline-asm
5139------------
5140This diagnostic is enabled by default.
5141
5142**Diagnostic text:**
5143
5144The text of this diagnostic is not controlled by Clang.
5145
5146
5147-Winline-new-delete
5148-------------------
5149This diagnostic is enabled by default.
5150
5151**Diagnostic text:**
5152
5153+----------------------------------------------------------------------------------------------------------------------------------+
5154|:warning:`warning:` |nbsp| :diagtext:`replacement function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be declared 'inline'`|
5155+----------------------------------------------------------------------------------------------------------------------------------+
5156
5157
5158-Winstantiation-after-specialization
5159------------------------------------
5160This diagnostic is enabled by default.
5161
5162**Diagnostic text:**
5163
5164+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5165|:warning:`warning:` |nbsp| :diagtext:`explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`that occurs after an explicit specialization has no effect`|
5166+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5167
5168
5169-Wint-conversion
5170----------------
5171This diagnostic is enabled by default.
5172
5173**Diagnostic text:**
5174
5175+-----------------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
5176|:warning:`warning:` |nbsp| :diagtext:`incompatible integer to pointer conversion` |nbsp| |+--------------------------------------------------------------+|+-------------------------------------+|
5177| ||:diagtext:`assigning to different types` ||| ||
5178| |+--------------------------------------------------------------+|+-------------------------------------+|
5179| ||:diagtext:`passing to parameter of different type` |||:diagtext:`; dereference with \*` ||
5180| |+--------------------------------------------------------------+|+-------------------------------------+|
5181| ||:diagtext:`returning from function with different return type`|||:diagtext:`; take the address with &`||
5182| |+--------------------------------------------------------------+|+-------------------------------------+|
5183| ||:diagtext:`converting between types` |||:diagtext:`; remove \*` ||
5184| |+--------------------------------------------------------------+|+-------------------------------------+|
5185| ||:diagtext:`initializing with expression of different type` |||:diagtext:`; remove &` ||
5186| |+--------------------------------------------------------------+|+-------------------------------------+|
5187| ||:diagtext:`sending to parameter of different type` || |
5188| |+--------------------------------------------------------------+| |
5189| ||:diagtext:`casting between types` || |
5190| |+--------------------------------------------------------------+| |
5191+-----------------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
5192
5193+-----------------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
5194|:warning:`warning:` |nbsp| :diagtext:`incompatible pointer to integer conversion` |nbsp| |+--------------------------------------------------------------+|+-------------------------------------+|
5195| ||:diagtext:`assigning to different types` ||| ||
5196| |+--------------------------------------------------------------+|+-------------------------------------+|
5197| ||:diagtext:`passing to parameter of different type` |||:diagtext:`; dereference with \*` ||
5198| |+--------------------------------------------------------------+|+-------------------------------------+|
5199| ||:diagtext:`returning from function with different return type`|||:diagtext:`; take the address with &`||
5200| |+--------------------------------------------------------------+|+-------------------------------------+|
5201| ||:diagtext:`converting between types` |||:diagtext:`; remove \*` ||
5202| |+--------------------------------------------------------------+|+-------------------------------------+|
5203| ||:diagtext:`initializing with expression of different type` |||:diagtext:`; remove &` ||
5204| |+--------------------------------------------------------------+|+-------------------------------------+|
5205| ||:diagtext:`sending to parameter of different type` || |
5206| |+--------------------------------------------------------------+| |
5207| ||:diagtext:`casting between types` || |
5208| |+--------------------------------------------------------------+| |
5209+-----------------------------------------------------------------------------------------+----------------------------------------------------------------+---------------------------------------+
5210
5211
5212-Wint-conversions
5213-----------------
5214Synonym for `-Wint-conversion`_.
5215
5216
5217-Wint-to-pointer-cast
5218---------------------
5219This diagnostic is enabled by default.
5220
5221Also controls `-Wint-to-void-pointer-cast`_.
5222
5223**Diagnostic text:**
5224
5225+-------------------------------------------------------------------------------------------------------------------------------------------+
5226|:warning:`warning:` |nbsp| :diagtext:`cast to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`from smaller integer type` |nbsp| :placeholder:`A`|
5227+-------------------------------------------------------------------------------------------------------------------------------------------+
5228
5229
5230-Wint-to-void-pointer-cast
5231--------------------------
5232This diagnostic is enabled by default.
5233
5234**Diagnostic text:**
5235
5236+-------------------------------------------------------------------------------------------------------------------------------------------+
5237|:warning:`warning:` |nbsp| :diagtext:`cast to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`from smaller integer type` |nbsp| :placeholder:`A`|
5238+-------------------------------------------------------------------------------------------------------------------------------------------+
5239
5240
5241-Winteger-overflow
5242------------------
5243This diagnostic is enabled by default.
5244
5245**Diagnostic text:**
5246
5247+-----------------------------------------------------------------------------------------------------------------------------------------------------+
5248|:warning:`warning:` |nbsp| :diagtext:`overflow in expression; result is` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with type` |nbsp| :placeholder:`B`|
5249+-----------------------------------------------------------------------------------------------------------------------------------------------------+
5250
5251
5252-Winvalid-command-line-argument
5253-------------------------------
5254This diagnostic is enabled by default.
5255
5256Also controls `-Wignored-optimization-argument`_.
5257
5258**Diagnostic text:**
5259
5260+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5261|:warning:`warning:` |nbsp| :diagtext:`optimization level '`:placeholder:`A`:diagtext:`' is not supported; using '`:placeholder:`B`:placeholder:`C`:diagtext:`' instead`|
5262+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5263
5264
5265-Winvalid-constexpr
5266-------------------
5267This diagnostic is an error by default, but the flag ``-Wno-invalid-constexpr`` can be used to disable the error.
5268
5269**Diagnostic text:**
5270
5271+----------------------------------------------------+-------------------------+--------------------------------------------------------+
5272|:error:`error:` |nbsp| :diagtext:`constexpr` |nbsp| |+-----------------------+| |nbsp| :diagtext:`never produces a constant expression`|
5273| ||:diagtext:`function` || |
5274| |+-----------------------+| |
5275| ||:diagtext:`constructor`|| |
5276| |+-----------------------+| |
5277+----------------------------------------------------+-------------------------+--------------------------------------------------------+
5278
5279
5280-Winvalid-iboutlet
5281------------------
5282This diagnostic is enabled by default.
5283
5284**Diagnostic text:**
5285
5286+---------------------------+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
5287|:warning:`warning:` |nbsp| |+-----------------------------+| |nbsp| :diagtext:`with` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute must be an object type (invalid` |nbsp| :placeholder:`B`:diagtext:`)`|
5288| ||:diagtext:`instance variable`|| |
5289| |+-----------------------------+| |
5290| ||:diagtext:`property` || |
5291| |+-----------------------------+| |
5292+---------------------------+-------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------+
5293
5294+---------------------------------------------------------------------------------------------------------+
5295|:warning:`warning:` |nbsp| :diagtext:`IBOutletCollection properties should be copy/strong and not assign`|
5296+---------------------------------------------------------------------------------------------------------+
5297
5298
5299-Winvalid-initializer-from-system-header
5300----------------------------------------
5301This diagnostic is enabled by default.
5302
5303**Diagnostic text:**
5304
5305+--------------------------------------------------------------------------------------------------------------+
5306|:warning:`warning:` |nbsp| :diagtext:`invalid constructor form class in system header, should not be explicit`|
5307+--------------------------------------------------------------------------------------------------------------+
5308
5309
5310-Winvalid-noreturn
5311------------------
5312This diagnostic is enabled by default.
5313
5314**Diagnostic text:**
5315
5316+-------------------------------------------------------------------------------------+
5317|:warning:`warning:` |nbsp| :diagtext:`function declared 'noreturn' should not return`|
5318+-------------------------------------------------------------------------------------+
5319
5320+--------------------------------------------------------------------------------------------------------------------------------+
5321|:warning:`warning:` |nbsp| :diagtext:`function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`declared 'noreturn' should not return`|
5322+--------------------------------------------------------------------------------------------------------------------------------+
5323
5324
5325-Winvalid-offsetof
5326------------------
5327This diagnostic is enabled by default.
5328
5329**Diagnostic text:**
5330
5331+----------------------------------------------------------------------------------------+
5332|:warning:`warning:` |nbsp| :diagtext:`offset of on non-POD type` |nbsp| :placeholder:`A`|
5333+----------------------------------------------------------------------------------------+
5334
5335+----------------------------------------------------------------------------------------------------+
5336|:warning:`warning:` |nbsp| :diagtext:`offset of on non-standard-layout type` |nbsp| :placeholder:`A`|
5337+----------------------------------------------------------------------------------------------------+
5338
5339
5340-Winvalid-or-nonexistent-directory
5341----------------------------------
5342Some of the diagnostics controlled by this flag are enabled by default.
5343
5344**Diagnostic text:**
5345
5346+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5347|:warning:`warning:` |nbsp| :diagtext:`environment variable SCE\_ORBIS\_SDK\_DIR is set, but points to invalid or nonexistent directory '`:placeholder:`A`:diagtext:`'`|
5348+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5349
5350+------------------------------------------------------------------------------------------------------------------------------------------------------------+
5351|:warning:`warning:` |nbsp| :diagtext:`unable to find` |nbsp| :placeholder:`A` |nbsp| :diagtext:`directory, expected to be in '`:placeholder:`B`:diagtext:`'`|
5352+------------------------------------------------------------------------------------------------------------------------------------------------------------+
5353
5354
5355-Winvalid-pch
5356-------------
5357This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
5358
5359-Winvalid-pp-token
5360------------------
5361This diagnostic is enabled by default.
5362
5363**Diagnostic text:**
5364
5365+---------------------------------------------------------------+
5366|:warning:`warning:` |nbsp| :diagtext:`empty character constant`|
5367+---------------------------------------------------------------+
5368
5369+------------------------------------------------------------------+-----------------+-----------------------------+
5370|:warning:`warning:` |nbsp| :diagtext:`missing terminating` |nbsp| |+---------------+| |nbsp| :diagtext:`character`|
5371| ||:diagtext:`'` || |
5372| |+---------------+| |
5373| ||:diagtext:`'"'`|| |
5374| |+---------------+| |
5375+------------------------------------------------------------------+-----------------+-----------------------------+
5376
5377
5378-Winvalid-source-encoding
5379-------------------------
5380This diagnostic is enabled by default.
5381
5382**Diagnostic text:**
5383
5384+--------------------------------------------------------------------------------------+
5385|:warning:`warning:` |nbsp| :diagtext:`illegal character encoding in character literal`|
5386+--------------------------------------------------------------------------------------+
5387
5388+-----------------------------------------------------------------------------------+
5389|:warning:`warning:` |nbsp| :diagtext:`illegal character encoding in string literal`|
5390+-----------------------------------------------------------------------------------+
5391
5392
5393-Winvalid-token-paste
5394---------------------
5395This diagnostic is an error by default, but the flag ``-Wno-invalid-token-paste`` can be used to disable the error.
5396
5397**Diagnostic text:**
5398
5399+----------------------------------------------------------------------------------------------------------------+
5400|:error:`error:` |nbsp| :diagtext:`pasting formed '`:placeholder:`A`:diagtext:`', an invalid preprocessing token`|
5401+----------------------------------------------------------------------------------------------------------------+
5402
5403
5404-Wjump-seh-finally
5405------------------
5406This diagnostic is enabled by default.
5407
5408**Diagnostic text:**
5409
5410+-------------------------------------------------------------------------------------------+
5411|:warning:`warning:` |nbsp| :diagtext:`jump out of \_\_finally block has undefined behavior`|
5412+-------------------------------------------------------------------------------------------+
5413
5414
5415-Wkeyword-compat
5416----------------
5417This diagnostic is enabled by default.
5418
5419**Diagnostic text:**
5420
5421+-----------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------+
5422|:warning:`warning:` |nbsp| :diagtext:`keyword '`:placeholder:`A`:diagtext:`' will be made available as an identifier` |nbsp| |+-----------------------------------------------------+|
5423| ||:diagtext:`here` ||
5424| |+-----------------------------------------------------+|
5425| ||:diagtext:`for the remainder of the translation unit`||
5426| |+-----------------------------------------------------+|
5427+-----------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------+
5428
5429
5430-Wkeyword-macro
5431---------------
5432**Diagnostic text:**
5433
5434+----------------------------------------------------------------------------+
5435|:warning:`warning:` |nbsp| :diagtext:`keyword is hidden by macro definition`|
5436+----------------------------------------------------------------------------+
5437
5438
5439-Wknr-promoted-parameter
5440------------------------
5441This diagnostic is enabled by default.
5442
5443**Diagnostic text:**
5444
5445+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5446|:warning:`warning:` |nbsp| :diagtext:`promoted type of K&R function parameter is not compatible with parameter type` |nbsp| :diagtext:`declared in a previous prototype`|
5447+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5448
5449
5450-Wlanguage-extension-token
5451--------------------------
5452**Diagnostic text:**
5453
5454+-----------------------------------------------------+
5455|:warning:`warning:` |nbsp| :diagtext:`extension used`|
5456+-----------------------------------------------------+
5457
5458
5459-Wlarge-by-value-copy
5460---------------------
5461This diagnostic is enabled by default.
5462
5463**Diagnostic text:**
5464
5465+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5466|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a large (`:placeholder:`B` |nbsp| :diagtext:`bytes) pass-by-value argument; pass it by reference instead ?`|
5467+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5468
5469+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5470|:warning:`warning:` |nbsp| :diagtext:`return value of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a large (`:placeholder:`B` |nbsp| :diagtext:`bytes) pass-by-value object; pass it by reference instead ?`|
5471+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5472
5473
5474-Wliblto
5475--------
5476This diagnostic is enabled by default.
5477
5478**Diagnostic text:**
5479
5480+-------------------------------------------------------------------------------------------------------------------------------------+
5481|:warning:`warning:` |nbsp| :diagtext:`libLTO.dylib relative to clang installed dir not found; using 'ld' default search path instead`|
5482+-------------------------------------------------------------------------------------------------------------------------------------+
5483
5484
5485-Wliteral-conversion
5486--------------------
5487This diagnostic is enabled by default.
5488
5489**Diagnostic text:**
5490
5491+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5492|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`changes value from` |nbsp| :placeholder:`C` |nbsp| :diagtext:`to` |nbsp| :placeholder:`D`|
5493+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5494
5495
5496-Wliteral-range
5497---------------
5498This diagnostic is enabled by default.
5499
5500**Diagnostic text:**
5501
5502+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5503|:warning:`warning:` |nbsp| :diagtext:`magnitude of floating-point constant too large for type` |nbsp| :placeholder:`A`:diagtext:`; maximum is` |nbsp| :placeholder:`B`|
5504+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5505
5506+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5507|:warning:`warning:` |nbsp| :diagtext:`magnitude of floating-point constant too small for type` |nbsp| :placeholder:`A`:diagtext:`; minimum is` |nbsp| :placeholder:`B`|
5508+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5509
5510
5511-Wlocal-type-template-args
5512--------------------------
5513Some of the diagnostics controlled by this flag are enabled by default.
5514
5515Also controls `-Wc++98-compat-local-type-template-args`_.
5516
5517**Diagnostic text:**
5518
5519+------------------------------------------------------------------------------------------------+
5520|:warning:`warning:` |nbsp| :diagtext:`template argument uses local type` |nbsp| :placeholder:`A`|
5521+------------------------------------------------------------------------------------------------+
5522
5523
5524-Wlogical-not-parentheses
5525-------------------------
5526This diagnostic is enabled by default.
5527
5528**Diagnostic text:**
5529
5530+-----------------------------------------------------------------------------------------------------------+
5531|:warning:`warning:` |nbsp| :diagtext:`logical not is only applied to the left hand side of this comparison`|
5532+-----------------------------------------------------------------------------------------------------------+
5533
5534
5535-Wlogical-op-parentheses
5536------------------------
5537This diagnostic is enabled by default.
5538
5539**Diagnostic text:**
5540
5541+---------------------------------------------------------+
5542|:warning:`warning:` |nbsp| :diagtext:`'&&' within '\|\|'`|
5543+---------------------------------------------------------+
5544
5545
5546-Wlong-long
5547-----------
5548Also controls `-Wc++11-long-long`_.
5549
5550**Diagnostic text:**
5551
5552+-----------------------------------------------------------------------------------------------+
5553|:warning:`warning:` |nbsp| :diagtext:`'long long' is an extension when C99 mode is not enabled`|
5554+-----------------------------------------------------------------------------------------------+
5555
5556
5557-Wloop-analysis
5558---------------
5559Controls `-Wfor-loop-analysis`_, `-Wrange-loop-analysis`_.
5560
5561
5562-Wmacro-redefined
5563-----------------
5564This diagnostic is enabled by default.
5565
5566**Diagnostic text:**
5567
5568+------------------------------------------------------------------------------+
5569|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`macro redefined`|
5570+------------------------------------------------------------------------------+
5571
5572
5573-Wmain
5574------
5575Some of the diagnostics controlled by this flag are enabled by default.
5576
5577**Diagnostic text:**
5578
5579+--------------------------------------------------------------------------------------------+
5580|:warning:`warning:` |nbsp| :diagtext:`ISO C++ does not allow 'main' to be used by a program`|
5581+--------------------------------------------------------------------------------------------+
5582
5583+--------------------------------------------------------------------------------------+
5584|:warning:`warning:` |nbsp| :diagtext:`'main' is not allowed to be declared \_Noreturn`|
5585+--------------------------------------------------------------------------------------+
5586
5587+------------------------------------------------------------------------------------+
5588|:warning:`warning:` |nbsp| :diagtext:`'main' is not allowed to be declared variadic`|
5589+------------------------------------------------------------------------------------+
5590
5591+-------------------------------------------------------------------------------+
5592|:warning:`warning:` |nbsp| :diagtext:`only one parameter on 'main' declaration`|
5593+-------------------------------------------------------------------------------+
5594
5595+---------------------------------------------------------------------------------------------------------+
5596|:warning:`warning:` |nbsp| :diagtext:`variable named 'main' with external linkage has undefined behavior`|
5597+---------------------------------------------------------------------------------------------------------+
5598
5599+---------------------------------------------------------------------------+
5600|:warning:`warning:` |nbsp| :diagtext:`'main' should not be declared static`|
5601+---------------------------------------------------------------------------+
5602
5603
5604-Wmain-return-type
5605------------------
5606This diagnostic is enabled by default.
5607
5608**Diagnostic text:**
5609
5610+-------------------------------------------------------------------------+
5611|:warning:`warning:` |nbsp| :diagtext:`return type of 'main' is not 'int'`|
5612+-------------------------------------------------------------------------+
5613
5614
5615-Wmalformed-warning-check
5616-------------------------
5617This diagnostic is enabled by default.
5618
5619**Diagnostic text:**
5620
5621+---------------------------------------------------------------------------------------------+
5622|:warning:`warning:` |nbsp| :diagtext:`\_\_has\_warning expected option name (e.g. "-Wundef")`|
5623+---------------------------------------------------------------------------------------------+
5624
5625
5626-Wmany-braces-around-scalar-init
5627--------------------------------
5628This diagnostic is enabled by default.
5629
5630**Diagnostic text:**
5631
5632+--------------------------------------------------------------------------------+
5633|:warning:`warning:` |nbsp| :diagtext:`too many braces around scalar initializer`|
5634+--------------------------------------------------------------------------------+
5635
5636
5637-Wmemsize-comparison
5638--------------------
5639This diagnostic is enabled by default.
5640
5641**Diagnostic text:**
5642
5643+-----------------------------------------------------------------------------------------------------------------------+
5644|:warning:`warning:` |nbsp| :diagtext:`size argument in` |nbsp| :placeholder:`A` |nbsp| :diagtext:`call is a comparison`|
5645+-----------------------------------------------------------------------------------------------------------------------+
5646
5647
5648-Wmethod-signatures
5649-------------------
5650**Diagnostic text:**
5651
5652+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5653|:warning:`warning:` |nbsp| :diagtext:`conflicting parameter types in implementation of` |nbsp| :placeholder:`A`:diagtext:`:` |nbsp| :placeholder:`B` |nbsp| :diagtext:`vs` |nbsp| :placeholder:`C`|
5654+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5655
5656+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5657|:warning:`warning:` |nbsp| :diagtext:`conflicting return type in implementation of` |nbsp| :placeholder:`A`:diagtext:`:` |nbsp| :placeholder:`B` |nbsp| :diagtext:`vs` |nbsp| :placeholder:`C`|
5658+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5659
5660
5661-Wmicrosoft
5662-----------
5663Some of the diagnostics controlled by this flag are enabled by default.
5664
5665Controls `-Wmicrosoft-charize`_, `-Wmicrosoft-include`_, `-Wmicrosoft-cpp-macro`_, `-Wmicrosoft-fixed-enum`_, `-Wmicrosoft-sealed`_, `-Wmicrosoft-unqualified-friend`_, `-Wmicrosoft-exception-spec`_, `-Wmicrosoft-using-decl`_, `-Wmicrosoft-mutable-reference`_, `-Wmicrosoft-pure-definition`_, `-Wmicrosoft-union-member-reference`_, `-Wmicrosoft-explicit-constructor-call`_, `-Wmicrosoft-enum-value`_, `-Wmicrosoft-default-arg-redefinition`_, `-Wmicrosoft-template`_, `-Wmicrosoft-redeclare-static`_, `-Wmicrosoft-enum-forward-reference`_, `-Wmicrosoft-goto`_, `-Wmicrosoft-flexible-array`_, `-Wmicrosoft-extra-qualification`_, `-Wmicrosoft-cast`_, `-Wmicrosoft-const-init`_, `-Wmicrosoft-void-pseudo-dtor`_, `-Wmicrosoft-anon-tag`_, `-Wmicrosoft-comment-paste`_, `-Wmicrosoft-end-of-file`_, `-Winconsistent-dllimport`_.
5666
5667
5668-Wmicrosoft-anon-tag
5669--------------------
5670Some of the diagnostics controlled by this flag are enabled by default.
5671
5672**Diagnostic text:**
5673
5674+-----------------------------------------------------------------------------+--------------------+---------------------------------------------+
5675|:warning:`warning:` |nbsp| :diagtext:`types declared in an anonymous` |nbsp| |+------------------+| |nbsp| :diagtext:`are a Microsoft extension`|
5676| ||:diagtext:`struct`|| |
5677| |+------------------+| |
5678| ||:diagtext:`union` || |
5679| |+------------------+| |
5680+-----------------------------------------------------------------------------+--------------------+---------------------------------------------+
5681
5682+--------------------------------------------------------+---------------------+---------------------------------------------+
5683|:warning:`warning:` |nbsp| :diagtext:`anonymous` |nbsp| |+-------------------+| |nbsp| :diagtext:`are a Microsoft extension`|
5684| ||:diagtext:`structs`|| |
5685| |+-------------------+| |
5686| ||:diagtext:`unions` || |
5687| |+-------------------+| |
5688+--------------------------------------------------------+---------------------+---------------------------------------------+
5689
5690
5691-Wmicrosoft-cast
5692----------------
5693This diagnostic is enabled by default.
5694
5695**Diagnostic text:**
5696
5697+------------------------------------------------------------------------------------------------------------------------------+
5698|:warning:`warning:` |nbsp| :diagtext:`static\_cast between pointer-to-function and pointer-to-object is a Microsoft extension`|
5699+------------------------------------------------------------------------------------------------------------------------------+
5700
5701+-------------------------------------------------------------------------------------------------------------------------------------+
5702|:warning:`warning:` |nbsp| :diagtext:`implicit conversion between pointer-to-function and pointer-to-object is a Microsoft extension`|
5703+-------------------------------------------------------------------------------------------------------------------------------------+
5704
5705
5706-Wmicrosoft-charize
5707-------------------
5708**Diagnostic text:**
5709
5710+-------------------------------------------------------------------------------------+
5711|:warning:`warning:` |nbsp| :diagtext:`charizing operator #@ is a Microsoft extension`|
5712+-------------------------------------------------------------------------------------+
5713
5714
5715-Wmicrosoft-comment-paste
5716-------------------------
5717**Diagnostic text:**
5718
5719+----------------------------------------------------------------------------------------------------------+
5720|:warning:`warning:` |nbsp| :diagtext:`pasting two '/' tokens into a '//' comment is a Microsoft extension`|
5721+----------------------------------------------------------------------------------------------------------+
5722
5723
5724-Wmicrosoft-const-init
5725----------------------
5726This diagnostic is enabled by default.
5727
5728**Diagnostic text:**
5729
5730+----------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------+--------------------------------------------+
5731|:warning:`warning:` |nbsp| :diagtext:`default initialization of an object of const type` |nbsp| :placeholder:`A`|+---------------------------------------------------------------+| |nbsp| :diagtext:`is a Microsoft extension`|
5732| || || |
5733| |+---------------------------------------------------------------+| |
5734| || |nbsp| :diagtext:`without a user-provided default constructor`|| |
5735| |+---------------------------------------------------------------+| |
5736+----------------------------------------------------------------------------------------------------------------+-----------------------------------------------------------------+--------------------------------------------+
5737
5738
5739-Wmicrosoft-cpp-macro
5740---------------------
5741**Diagnostic text:**
5742
5743+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
5744|:warning:`warning:` |nbsp| :diagtext:`C++ operator` |nbsp| :placeholder:`A` |nbsp| :diagtext:`(aka` |nbsp| :placeholder:`B`:diagtext:`) used as a macro name`|
5745+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
5746
5747
5748-Wmicrosoft-default-arg-redefinition
5749------------------------------------
5750This diagnostic is enabled by default.
5751
5752**Diagnostic text:**
5753
5754+-----------------------------------------------------------------------+
5755|:warning:`warning:` |nbsp| :diagtext:`redefinition of default argument`|
5756+-----------------------------------------------------------------------+
5757
5758
5759-Wmicrosoft-end-of-file
5760-----------------------
5761**Diagnostic text:**
5762
5763+----------------------------------------------------------------------------------------------+
5764|:warning:`warning:` |nbsp| :diagtext:`treating Ctrl-Z as end-of-file is a Microsoft extension`|
5765+----------------------------------------------------------------------------------------------+
5766
5767
5768-Wmicrosoft-enum-forward-reference
5769----------------------------------
5770**Diagnostic text:**
5771
5772+---------------------------------------------------------------------------------------------------+
5773|:warning:`warning:` |nbsp| :diagtext:`forward references to 'enum' types are a Microsoft extension`|
5774+---------------------------------------------------------------------------------------------------+
5775
5776
5777-Wmicrosoft-enum-value
5778----------------------
5779This diagnostic is enabled by default.
5780
5781**Diagnostic text:**
5782
5783+---------------------------------------------------------------------------------------------------------------------------+
5784|:warning:`warning:` |nbsp| :diagtext:`enumerator value is not representable in the underlying type` |nbsp| :placeholder:`A`|
5785+---------------------------------------------------------------------------------------------------------------------------+
5786
5787
5788-Wmicrosoft-exception-spec
5789--------------------------
5790Some of the diagnostics controlled by this flag are enabled by default.
5791
5792**Diagnostic text:**
5793
5794+------------------------------------------------------------------------------------------------+
5795|:warning:`warning:` |nbsp| :diagtext:`exception specification of '...' is a Microsoft extension`|
5796+------------------------------------------------------------------------------------------------+
5797
5798+---------------------------+----------------------------------+----------------------------------------------------------------------------------------------------------------+
5799|:warning:`warning:` |nbsp| |+--------------------------------+|:diagtext:`incomplete type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is not allowed in exception specification`|
5800| || || |
5801| |+--------------------------------+| |
5802| ||:diagtext:`pointer to` |nbsp| || |
5803| |+--------------------------------+| |
5804| ||:diagtext:`reference to` |nbsp| || |
5805| |+--------------------------------+| |
5806+---------------------------+----------------------------------+----------------------------------------------------------------------------------------------------------------+
5807
5808+-----------------------------------------------------------------------------------------------------------------+
5809|:warning:`warning:` |nbsp| :diagtext:`exception specification in declaration does not match previous declaration`|
5810+-----------------------------------------------------------------------------------------------------------------+
5811
5812+------------------------------------------------------------------------------------------------------------------------+
5813|:warning:`warning:` |nbsp| :diagtext:`exception specification in explicit instantiation does not match instantiated one`|
5814+------------------------------------------------------------------------------------------------------------------------+
5815
5816+--------------------------------------------------------------------------------------------------------------------------------+
5817|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is missing exception specification '`:placeholder:`B`:diagtext:`'`|
5818+--------------------------------------------------------------------------------------------------------------------------------+
5819
5820+-------------------------------------------------------------------------------------------------------------------+
5821|:warning:`warning:` |nbsp| :diagtext:`exception specification of overriding function is more lax than base version`|
5822+-------------------------------------------------------------------------------------------------------------------+
5823
5824
5825-Wmicrosoft-exists
5826------------------
5827This diagnostic is enabled by default.
5828
5829**Diagnostic text:**
5830
5831+--------------------------------------------------------+---------------------------------+--------------------------------------------+
5832|:warning:`warning:` |nbsp| :diagtext:`dependent` |nbsp| |+-------------------------------+| |nbsp| :diagtext:`declarations are ignored`|
5833| ||:diagtext:`\_\_if\_not\_exists`|| |
5834| |+-------------------------------+| |
5835| ||:diagtext:`\_\_if\_exists` || |
5836| |+-------------------------------+| |
5837+--------------------------------------------------------+---------------------------------+--------------------------------------------+
5838
5839
5840-Wmicrosoft-explicit-constructor-call
5841-------------------------------------
5842This diagnostic is enabled by default.
5843
5844**Diagnostic text:**
5845
5846+-------------------------------------------------------------------------------------------+
5847|:warning:`warning:` |nbsp| :diagtext:`explicit constructor calls are a Microsoft extension`|
5848+-------------------------------------------------------------------------------------------+
5849
5850
5851-Wmicrosoft-extra-qualification
5852-------------------------------
5853This diagnostic is enabled by default.
5854
5855**Diagnostic text:**
5856
5857+--------------------------------------------------------------------------------------------+
5858|:warning:`warning:` |nbsp| :diagtext:`extra qualification on member` |nbsp| :placeholder:`A`|
5859+--------------------------------------------------------------------------------------------+
5860
5861
5862-Wmicrosoft-fixed-enum
5863----------------------
5864**Diagnostic text:**
5865
5866+---------------------------------------------------------------------------------------------------------------+
5867|:warning:`warning:` |nbsp| :diagtext:`enumeration types with a fixed underlying type are a Microsoft extension`|
5868+---------------------------------------------------------------------------------------------------------------+
5869
5870
5871-Wmicrosoft-flexible-array
5872--------------------------
5873**Diagnostic text:**
5874
5875+----------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------------+
5876|:warning:`warning:` |nbsp| :diagtext:`flexible array member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in otherwise empty` |nbsp| |+---------------------+| |nbsp| :diagtext:`is a Microsoft extension`|
5877| ||:diagtext:`struct` || |
5878| |+---------------------+| |
5879| ||:diagtext:`interface`|| |
5880| |+---------------------+| |
5881| ||:diagtext:`union` || |
5882| |+---------------------+| |
5883| ||:diagtext:`class` || |
5884| |+---------------------+| |
5885| ||:diagtext:`enum` || |
5886| |+---------------------+| |
5887+----------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------------+
5888
5889+-------------------------------------------------------------------------------------------------------------------------------------------+
5890|:warning:`warning:` |nbsp| :diagtext:`flexible array member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in a union is a Microsoft extension`|
5891+-------------------------------------------------------------------------------------------------------------------------------------------+
5892
5893
5894-Wmicrosoft-goto
5895----------------
5896This diagnostic is enabled by default.
5897
5898**Diagnostic text:**
5899
5900+----------------------------------------------------------------------------------------------------------+
5901|:warning:`warning:` |nbsp| :diagtext:`jump from this goto statement to its label is a Microsoft extension`|
5902+----------------------------------------------------------------------------------------------------------+
5903
5904
5905-Wmicrosoft-include
5906-------------------
5907This diagnostic is enabled by default.
5908
5909**Diagnostic text:**
5910
5911+------------------------------------------------------------------------------------------------------------------------------+
5912|:warning:`warning:` |nbsp| :diagtext:`#include resolved using non-portable Microsoft search rules as:` |nbsp| :placeholder:`A`|
5913+------------------------------------------------------------------------------------------------------------------------------+
5914
5915
5916-Wmicrosoft-mutable-reference
5917-----------------------------
5918This diagnostic is enabled by default.
5919
5920**Diagnostic text:**
5921
5922+---------------------------------------------------------------------------------------------+
5923|:warning:`warning:` |nbsp| :diagtext:`'mutable' on a reference type is a Microsoft extension`|
5924+---------------------------------------------------------------------------------------------+
5925
5926
5927-Wmicrosoft-pure-definition
5928---------------------------
5929This diagnostic is enabled by default.
5930
5931**Diagnostic text:**
5932
5933+-------------------------------------------------------------------------------------------------------+
5934|:warning:`warning:` |nbsp| :diagtext:`function definition with pure-specifier is a Microsoft extension`|
5935+-------------------------------------------------------------------------------------------------------+
5936
5937
5938-Wmicrosoft-redeclare-static
5939----------------------------
5940**Diagnostic text:**
5941
5942+-------------------------------------------------------------------------------------------------------------------------------------------+
5943|:warning:`warning:` |nbsp| :diagtext:`redeclaring non-static` |nbsp| :placeholder:`A` |nbsp| :diagtext:`as static is a Microsoft extension`|
5944+-------------------------------------------------------------------------------------------------------------------------------------------+
5945
5946
5947-Wmicrosoft-sealed
5948------------------
5949This diagnostic is enabled by default.
5950
5951**Diagnostic text:**
5952
5953+--------------------------------------------------------------------------------+
5954|:warning:`warning:` |nbsp| :diagtext:`'sealed' keyword is a Microsoft extension`|
5955+--------------------------------------------------------------------------------+
5956
5957
5958-Wmicrosoft-template
5959--------------------
5960This diagnostic is enabled by default.
5961
5962**Diagnostic text:**
5963
5964+------------------------------------------------------------------------------------------------------------------------------------------------------+
5965|:warning:`warning:` |nbsp| :diagtext:`duplicate explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored as a Microsoft extension`|
5966+------------------------------------------------------------------------------------------------------------------------------------------------------+
5967
5968+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5969|:warning:`warning:` |nbsp| :diagtext:`use of identifier` |nbsp| :placeholder:`A` |nbsp| :diagtext:`found via unqualified lookup into dependent bases of class templates is a Microsoft extension`|
5970+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5971
5972+--------------------------------------------------------------------------------------------------------------------------------------------------------+
5973|:warning:`warning:` |nbsp| :diagtext:`explicit specialization of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`within class scope is a Microsoft extension`|
5974+--------------------------------------------------------------------------------------------------------------------------------------------------------+
5975
5976+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5977|:warning:`warning:` |nbsp| :diagtext:`using the undeclared type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`as a default template argument is a Microsoft extension`|
5978+-------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5979
5980+-----------------------------------------------------------------------------------------------------------------------------+
5981|:warning:`warning:` |nbsp| :diagtext:`non-type template argument containing a dereference operation is a Microsoft extension`|
5982+-----------------------------------------------------------------------------------------------------------------------------+
5983
5984+---------------------------+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
5985|:warning:`warning:` |nbsp| |+-------------------------------------+| |nbsp| :diagtext:`specialization of` |nbsp| :placeholder:`B` |nbsp| :diagtext:`outside namespace enclosing` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is a Microsoft extension`|
5986| ||:diagtext:`class template` || |
5987| |+-------------------------------------+| |
5988| ||:diagtext:`class template partial` || |
5989| |+-------------------------------------+| |
5990| ||:diagtext:`variable template` || |
5991| |+-------------------------------------+| |
5992| ||:diagtext:`variable template partial`|| |
5993| |+-------------------------------------+| |
5994| ||:diagtext:`function template` || |
5995| |+-------------------------------------+| |
5996| ||:diagtext:`member function` || |
5997| |+-------------------------------------+| |
5998| ||:diagtext:`static data member` || |
5999| |+-------------------------------------+| |
6000| ||:diagtext:`member class` || |
6001| |+-------------------------------------+| |
6002| ||:diagtext:`member enumeration` || |
6003| |+-------------------------------------+| |
6004+---------------------------+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6005
6006+------------------------------------------------------------------------------------------------------------------------------------------------+
6007|:warning:`warning:` |nbsp| :diagtext:`template argument for template type parameter must be a type; omitted 'typename' is a Microsoft extension`|
6008+------------------------------------------------------------------------------------------------------------------------------------------------+
6009
6010+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6011|:warning:`warning:` |nbsp| :diagtext:`use of undeclared identifier` |nbsp| :placeholder:`A`:diagtext:`; unqualified lookup into dependent bases of class template` |nbsp| :placeholder:`B` |nbsp| :diagtext:`is a Microsoft extension`|
6012+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6013
6014
6015-Wmicrosoft-union-member-reference
6016----------------------------------
6017This diagnostic is enabled by default.
6018
6019**Diagnostic text:**
6020
6021+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6022|:warning:`warning:` |nbsp| :diagtext:`union member` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has reference type` |nbsp| :placeholder:`B`:diagtext:`, which is a Microsoft extension`|
6023+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6024
6025
6026-Wmicrosoft-unqualified-friend
6027------------------------------
6028This diagnostic is enabled by default.
6029
6030**Diagnostic text:**
6031
6032+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6033|:warning:`warning:` |nbsp| :diagtext:`unqualified friend declaration referring to type outside of the nearest enclosing namespace is a Microsoft extension; add a nested name specifier`|
6034+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6035
6036
6037-Wmicrosoft-using-decl
6038----------------------
6039This diagnostic is enabled by default.
6040
6041**Diagnostic text:**
6042
6043+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6044|:warning:`warning:` |nbsp| :diagtext:`using declaration referring to inaccessible member '`:placeholder:`A`:diagtext:`' (which refers to accessible member '`:placeholder:`B`:diagtext:`') is a Microsoft compatibility extension`|
6045+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6046
6047
6048-Wmicrosoft-void-pseudo-dtor
6049----------------------------
6050This diagnostic is enabled by default.
6051
6052**Diagnostic text:**
6053
6054+------------------------------------------------------------------------------------------------+
6055|:warning:`warning:` |nbsp| :diagtext:`pseudo-destructors on type void are a Microsoft extension`|
6056+------------------------------------------------------------------------------------------------+
6057
6058
6059-Wmismatched-new-delete
6060-----------------------
6061This diagnostic is enabled by default.
6062
6063**Diagnostic text:**
6064
6065+----------------------------------------------+------------------+---------------------------------------------------------------+------------------+-----------------------------------+------------------+--------------+
6066|:warning:`warning:` |nbsp| :diagtext:`'delete`|+----------------+|:diagtext:`' applied to a pointer that was allocated with 'new`|+----------------+|:diagtext:`'; did you mean 'delete`|+----------------+|:diagtext:`'?`|
6067| || || ||:diagtext:`\[\]`|| ||:diagtext:`\[\]`|| |
6068| |+----------------+| |+----------------+| |+----------------+| |
6069| ||:diagtext:`\[\]`|| || || || || |
6070| |+----------------+| |+----------------+| |+----------------+| |
6071+----------------------------------------------+------------------+---------------------------------------------------------------+------------------+-----------------------------------+------------------+--------------+
6072
6073
6074-Wmismatched-parameter-types
6075----------------------------
6076This diagnostic is enabled by default.
6077
6078**Diagnostic text:**
6079
6080+---------------------------------------------------------------------------------------------------------------+
6081|:warning:`warning:` |nbsp| :diagtext:`conflicting parameter types in implementation of` |nbsp| :placeholder:`A`|
6082+---------------------------------------------------------------------------------------------------------------+
6083
6084
6085-Wmismatched-return-types
6086-------------------------
6087This diagnostic is enabled by default.
6088
6089**Diagnostic text:**
6090
6091+-----------------------------------------------------------------------------------------------------------+
6092|:warning:`warning:` |nbsp| :diagtext:`conflicting return type in implementation of` |nbsp| :placeholder:`A`|
6093+-----------------------------------------------------------------------------------------------------------+
6094
6095
6096-Wmismatched-tags
6097-----------------
6098**Diagnostic text:**
6099
6100+---------------------------------------------------------------------------------+--------------------------+------------------------------+-----------------------------------------------------------+--------------------------+------------------------------+
6101|:warning:`warning:` |nbsp| :placeholder:`C` |nbsp| :diagtext:`defined as` |nbsp| |+------------------------+|+----------------------------+| |nbsp| :diagtext:`here but previously declared as` |nbsp| |+------------------------+|+----------------------------+|
6102| ||:diagtext:`a struct` ||| || ||:diagtext:`a struct` ||| ||
6103| |+------------------------+|+----------------------------+| |+------------------------+|+----------------------------+|
6104| ||:diagtext:`an interface`||| |nbsp| :diagtext:`template`|| ||:diagtext:`an interface`||| |nbsp| :diagtext:`template`||
6105| |+------------------------+|+----------------------------+| |+------------------------+|+----------------------------+|
6106| ||:diagtext:`a class` || | ||:diagtext:`a class` || |
6107| |+------------------------+| | |+------------------------+| |
6108+---------------------------------------------------------------------------------+--------------------------+------------------------------+-----------------------------------------------------------+--------------------------+------------------------------+
6109
6110+---------------------------+-----------------------+------------------------------+--------------------------------------------------------------------------------+-----------------------+------------------------------+
6111|:warning:`warning:` |nbsp| |+---------------------+|+----------------------------+| |nbsp| :placeholder:`C` |nbsp| :diagtext:`was previously declared as a` |nbsp| |+---------------------+|+----------------------------+|
6112| ||:diagtext:`struct` ||| || ||:diagtext:`struct` ||| ||
6113| |+---------------------+|+----------------------------+| |+---------------------+|+----------------------------+|
6114| ||:diagtext:`interface`||| |nbsp| :diagtext:`template`|| ||:diagtext:`interface`||| |nbsp| :diagtext:`template`||
6115| |+---------------------+|+----------------------------+| |+---------------------+|+----------------------------+|
6116| ||:diagtext:`class` || | ||:diagtext:`class` || |
6117| |+---------------------+| | |+---------------------+| |
6118+---------------------------+-----------------------+------------------------------+--------------------------------------------------------------------------------+-----------------------+------------------------------+
6119
6120
6121-Wmissing-braces
6122----------------
6123**Diagnostic text:**
6124
6125+----------------------------------------------------------------------------------------+
6126|:warning:`warning:` |nbsp| :diagtext:`suggest braces around initialization of subobject`|
6127+----------------------------------------------------------------------------------------+
6128
6129
6130-Wmissing-declarations
6131----------------------
6132This diagnostic is enabled by default.
6133
6134**Diagnostic text:**
6135
6136+----------------------------------------------------------------------------+
6137|:warning:`warning:` |nbsp| :diagtext:`declaration does not declare anything`|
6138+----------------------------------------------------------------------------+
6139
6140+-----------------------------------------------------------------------------------------------------------------+
6141|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' is not permitted on a declaration of a type`|
6142+-----------------------------------------------------------------------------------------------------------------+
6143
6144+--------------------------------------------------------------+
6145|:warning:`warning:` |nbsp| :diagtext:`typedef requires a name`|
6146+--------------------------------------------------------------+
6147
6148+-------------------------------------------------------------------------------------------------+
6149|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' ignored on this declaration`|
6150+-------------------------------------------------------------------------------------------------+
6151
6152
6153-Wmissing-exception-spec
6154------------------------
6155This diagnostic is enabled by default.
6156
6157**Diagnostic text:**
6158
6159+--------------------------------------------------------------------------------------------------------------------------------+
6160|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is missing exception specification '`:placeholder:`B`:diagtext:`'`|
6161+--------------------------------------------------------------------------------------------------------------------------------+
6162
6163
6164-Wmissing-field-initializers
6165----------------------------
6166**Diagnostic text:**
6167
6168+-----------------------------------------------------------------------------------------------------------+
6169|:warning:`warning:` |nbsp| :diagtext:`missing field` |nbsp| :placeholder:`A` |nbsp| :diagtext:`initializer`|
6170+-----------------------------------------------------------------------------------------------------------+
6171
6172
6173-Wmissing-format-attribute
6174--------------------------
6175This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
6176
6177-Wmissing-include-dirs
6178----------------------
6179This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
6180
6181-Wmissing-method-return-type
6182----------------------------
6183**Diagnostic text:**
6184
6185+--------------------------------------------------------------------------------------------+
6186|:warning:`warning:` |nbsp| :diagtext:`method has no return type specified; defaults to 'id'`|
6187+--------------------------------------------------------------------------------------------+
6188
6189
6190-Wmissing-noreturn
6191------------------
6192**Diagnostic text:**
6193
6194+----------------------------------------------------------------------------------------+
6195|:warning:`warning:` |nbsp| :diagtext:`block could be declared with attribute 'noreturn'`|
6196+----------------------------------------------------------------------------------------+
6197
6198+---------------------------+----------------------+---------------------------------------------------------------------------------------+
6199|:warning:`warning:` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`could be declared with attribute 'noreturn'`|
6200| ||:diagtext:`function`|| |
6201| |+--------------------+| |
6202| ||:diagtext:`method` || |
6203| |+--------------------+| |
6204+---------------------------+----------------------+---------------------------------------------------------------------------------------+
6205
6206
6207-Wmissing-prototype-for-cc
6208--------------------------
6209This diagnostic is enabled by default.
6210
6211**Diagnostic text:**
6212
6213+----------------------------------------------------------------------------------------------------------------------------------------------+
6214|:warning:`warning:` |nbsp| :diagtext:`function with no prototype cannot use the` |nbsp| :placeholder:`A` |nbsp| :diagtext:`calling convention`|
6215+----------------------------------------------------------------------------------------------------------------------------------------------+
6216
6217
6218-Wmissing-prototypes
6219--------------------
6220**Diagnostic text:**
6221
6222+-------------------------------------------------------------------------------------------------+
6223|:warning:`warning:` |nbsp| :diagtext:`no previous prototype for function` |nbsp| :placeholder:`A`|
6224+-------------------------------------------------------------------------------------------------+
6225
6226
6227-Wmissing-selector-name
6228-----------------------
6229This diagnostic is enabled by default.
6230
6231**Diagnostic text:**
6232
6233+---------------------------------------------------------------------------------------------------------------------------------------------+
6234|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`used as the name of the previous parameter rather than as part of the selector`|
6235+---------------------------------------------------------------------------------------------------------------------------------------------+
6236
6237
6238-Wmissing-sysroot
6239-----------------
6240This diagnostic is enabled by default.
6241
6242**Diagnostic text:**
6243
6244+------------------------------------------------------------------------------------------------+
6245|:warning:`warning:` |nbsp| :diagtext:`no such sysroot directory: '`:placeholder:`A`:diagtext:`'`|
6246+------------------------------------------------------------------------------------------------+
6247
6248
6249-Wmissing-variable-declarations
6250-------------------------------
6251**Diagnostic text:**
6252
6253+---------------------------------------------------------------------------------------------------------------------+
6254|:warning:`warning:` |nbsp| :diagtext:`no previous extern declaration for non-static variable` |nbsp| :placeholder:`A`|
6255+---------------------------------------------------------------------------------------------------------------------+
6256
6257
6258-Rmodule-build
6259--------------
6260**Diagnostic text:**
6261
6262+---------------------------------------------------------------------------------------------------------------------+
6263|:remark:`remark:` |nbsp| :diagtext:`building module '`:placeholder:`A`:diagtext:`' as '`:placeholder:`B`:diagtext:`'`|
6264+---------------------------------------------------------------------------------------------------------------------+
6265
6266+--------------------------------------------------------------------------------------------+
6267|:remark:`remark:` |nbsp| :diagtext:`finished building module '`:placeholder:`A`:diagtext:`'`|
6268+--------------------------------------------------------------------------------------------+
6269
6270
6271-Wmodule-conflict
6272-----------------
6273This diagnostic is enabled by default.
6274
6275**Diagnostic text:**
6276
6277+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6278|:warning:`warning:` |nbsp| :diagtext:`module '`:placeholder:`A`:diagtext:`' conflicts with already-imported module '`:placeholder:`B`:diagtext:`':` |nbsp| :placeholder:`C`|
6279+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6280
6281
6282-Wmodule-file-config-mismatch
6283-----------------------------
6284This diagnostic is an error by default, but the flag ``-Wno-module-file-config-mismatch`` can be used to disable the error.
6285
6286**Diagnostic text:**
6287
6288+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6289|:error:`error:` |nbsp| :diagtext:`module file` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be loaded due to a configuration mismatch with the current compilation`|
6290+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6291
6292
6293-Wmodule-file-extension
6294-----------------------
6295This diagnostic is enabled by default.
6296
6297**Diagnostic text:**
6298
6299+----------------------------------------------------------------------------------------------------------------+
6300|:warning:`warning:` |nbsp| :diagtext:`duplicate module file extension block name '`:placeholder:`A`:diagtext:`'`|
6301+----------------------------------------------------------------------------------------------------------------+
6302
6303
6304-Wmodule-import-in-extern-c
6305---------------------------
6306This diagnostic is an error by default, but the flag ``-Wno-module-import-in-extern-c`` can be used to disable the error.
6307
6308**Diagnostic text:**
6309
6310+-----------------------------------------------------------------------------------------------------------------------------------------------+
6311|:error:`error:` |nbsp| :diagtext:`import of C++ module '`:placeholder:`A`:diagtext:`' appears within extern "C" language linkage specification`|
6312+-----------------------------------------------------------------------------------------------------------------------------------------------+
6313
6314
6315-Wmodules-ambiguous-internal-linkage
6316------------------------------------
6317This diagnostic is enabled by default.
6318
6319**Diagnostic text:**
6320
6321+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
6322|:warning:`warning:` |nbsp| :diagtext:`ambiguous use of internal linkage declaration` |nbsp| :placeholder:`A` |nbsp| :diagtext:`defined in multiple modules`|
6323+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
6324
6325
6326-Wmodules-import-nested-redundant
6327---------------------------------
6328This diagnostic is an error by default, but the flag ``-Wno-modules-import-nested-redundant`` can be used to disable the error.
6329
6330**Diagnostic text:**
6331
6332+-------------------------------------------------------------------------------------------------------------------------------------+
6333|:error:`error:` |nbsp| :diagtext:`redundant #include of module '`:placeholder:`A`:diagtext:`' appears within` |nbsp| :placeholder:`B`|
6334+-------------------------------------------------------------------------------------------------------------------------------------+
6335
6336
6337-Wmost
6338------
6339Some of the diagnostics controlled by this flag are enabled by default.
6340
6341Controls `-Wchar-subscripts`_, `-Wcomment`_, `-Wdelete-non-virtual-dtor`_, `-Wfor-loop-analysis`_, `-Wformat`_, `-Wimplicit`_, `-Winfinite-recursion`_, `-Wmismatched-tags`_, `-Wmissing-braces`_, `-Wmove`_, `-Wmultichar`_, `-Wreorder`_, `-Wreturn-type`_, `-Wself-assign`_, `-Wself-move`_, `-Wsizeof-array-argument`_, `-Wsizeof-array-decay`_, `-Wstring-plus-int`_, `-Wtrigraphs`_, `-Wuninitialized`_, `-Wunknown-pragmas`_, `-Wunused`_, `-Wvolatile-register-var`_, `-Wobjc-missing-super-calls`_, `-Wobjc-designated-initializers`_, `-Woverloaded-virtual`_, `-Wprivate-extern`_, `-Wcast-of-sel-type`_, `-Wextern-c-compat`_.
6342
6343
6344-Wmove
6345------
6346Controls `-Wpessimizing-move`_, `-Wredundant-move`_, `-Wself-move`_.
6347
6348
6349-Wmsvc-include
6350--------------
6351Synonym for `-Wmicrosoft-include`_.
6352
6353
6354-Wmultichar
6355-----------
6356This diagnostic is enabled by default.
6357
6358**Diagnostic text:**
6359
6360+-------------------------------------------------------------------------+
6361|:warning:`warning:` |nbsp| :diagtext:`multi-character character constant`|
6362+-------------------------------------------------------------------------+
6363
6364
6365-Wmultiple-move-vbase
6366---------------------
6367This diagnostic is enabled by default.
6368
6369**Diagnostic text:**
6370
6371+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6372|:warning:`warning:` |nbsp| :diagtext:`defaulted move assignment operator of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will move assign virtual base class` |nbsp| :placeholder:`B` |nbsp| :diagtext:`multiple times`|
6373+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6374
6375
6376-Wnarrowing
6377-----------
6378Synonym for `-Wc++11-narrowing`_.
6379
6380
6381-Wnested-anon-types
6382-------------------
6383**Diagnostic text:**
6384
6385+---------------------------------------------------------------------------------------+--------------------+------------------------------------+
6386|:warning:`warning:` |nbsp| :diagtext:`anonymous types declared in an anonymous` |nbsp| |+------------------+| |nbsp| :diagtext:`are an extension`|
6387| ||:diagtext:`struct`|| |
6388| |+------------------+| |
6389| ||:diagtext:`union` || |
6390| |+------------------+| |
6391+---------------------------------------------------------------------------------------+--------------------+------------------------------------+
6392
6393
6394-Wnested-externs
6395----------------
6396This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
6397
6398-Wnew-returns-null
6399------------------
6400This diagnostic is enabled by default.
6401
6402**Diagnostic text:**
6403
6404+-------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+
6405|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`should not return a null pointer unless it is declared 'throw()'`|+---------------------------------+|
6406| || ||
6407| |+---------------------------------+|
6408| || |nbsp| :diagtext:`or 'noexcept'`||
6409| |+---------------------------------+|
6410+-------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+
6411
6412
6413-Wnewline-eof
6414-------------
6415**Diagnostic text:**
6416
6417+----------------------------------------------------------------+
6418|:warning:`warning:` |nbsp| :diagtext:`no newline at end of file`|
6419+----------------------------------------------------------------+
6420
6421+----------------------------------------------------------------+
6422|:warning:`warning:` |nbsp| :diagtext:`no newline at end of file`|
6423+----------------------------------------------------------------+
6424
6425
6426-Wnon-gcc
6427---------
6428Some of the diagnostics controlled by this flag are enabled by default.
6429
6430Controls `-Wsign-compare`_, `-Wconversion`_, `-Wliteral-range`_.
6431
6432
6433-Wnon-literal-null-conversion
6434-----------------------------
6435This diagnostic is enabled by default.
6436
6437**Diagnostic text:**
6438
6439+--------------------------------------------------------------------------------------------------------------------------------------------+
6440|:warning:`warning:` |nbsp| :diagtext:`expression which evaluates to zero treated as a null pointer constant of type` |nbsp| :placeholder:`A`|
6441+--------------------------------------------------------------------------------------------------------------------------------------------+
6442
6443
6444-Wnon-modular-include-in-framework-module
6445-----------------------------------------
6446**Diagnostic text:**
6447
6448+---------------------------------------------------------------------------------------------------------------------------+
6449|:warning:`warning:` |nbsp| :diagtext:`include of non-modular header inside framework module '`:placeholder:`A`:diagtext:`'`|
6450+---------------------------------------------------------------------------------------------------------------------------+
6451
6452
6453-Wnon-modular-include-in-module
6454-------------------------------
6455Also controls `-Wnon-modular-include-in-framework-module`_.
6456
6457**Diagnostic text:**
6458
6459+-----------------------------------------------------------------------------------------------------------------+
6460|:warning:`warning:` |nbsp| :diagtext:`include of non-modular header inside module '`:placeholder:`A`:diagtext:`'`|
6461+-----------------------------------------------------------------------------------------------------------------+
6462
6463
6464-Wnon-pod-varargs
6465-----------------
6466This diagnostic is an error by default, but the flag ``-Wno-non-pod-varargs`` can be used to disable the error.
6467
6468**Diagnostic text:**
6469
6470+----------------------------------------------------------------+-------------------------+--------------------------------------------------------------------------------------------+-------------------------+----------------------------------------+
6471|:error:`error:` |nbsp| :diagtext:`cannot pass object of` |nbsp| |+-----------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`through variadic` |nbsp| |+-----------------------+|:diagtext:`; call will abort at runtime`|
6472| ||:diagtext:`non-POD` || ||:diagtext:`function` || |
6473| |+-----------------------+| |+-----------------------+| |
6474| ||:diagtext:`non-trivial`|| ||:diagtext:`block` || |
6475| |+-----------------------+| |+-----------------------+| |
6476| | | ||:diagtext:`method` || |
6477| | | |+-----------------------+| |
6478| | | ||:diagtext:`constructor`|| |
6479| | | |+-----------------------+| |
6480+----------------------------------------------------------------+-------------------------+--------------------------------------------------------------------------------------------+-------------------------+----------------------------------------+
6481
6482+------------------------------------------------------+-------------------------+-------------------------------------------------------------------------------------------------+-------------------------+--------------------------------------------------------------------------+
6483|:error:`error:` |nbsp| :diagtext:`cannot pass` |nbsp| |+-----------------------+| |nbsp| :diagtext:`object of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`to variadic` |nbsp| |+-----------------------+|:diagtext:`; expected type from format string was` |nbsp| :placeholder:`D`|
6484| ||:diagtext:`non-POD` || ||:diagtext:`function` || |
6485| |+-----------------------+| |+-----------------------+| |
6486| ||:diagtext:`non-trivial`|| ||:diagtext:`block` || |
6487| |+-----------------------+| |+-----------------------+| |
6488| | | ||:diagtext:`method` || |
6489| | | |+-----------------------+| |
6490| | | ||:diagtext:`constructor`|| |
6491| | | |+-----------------------+| |
6492+------------------------------------------------------+-------------------------+-------------------------------------------------------------------------------------------------+-------------------------+--------------------------------------------------------------------------+
6493
6494+----------------------------------------------------------------------------------------------------------+
6495|:error:`error:` |nbsp| :diagtext:`second argument to 'va\_arg' is of non-POD type` |nbsp| :placeholder:`A`|
6496+----------------------------------------------------------------------------------------------------------+
6497
6498+--------------------------------------------------------------------------------------------------------------------------+
6499|:error:`error:` |nbsp| :diagtext:`second argument to 'va\_arg' is of ARC ownership-qualified type` |nbsp| :placeholder:`A`|
6500+--------------------------------------------------------------------------------------------------------------------------+
6501
6502
6503-Wnon-virtual-dtor
6504------------------
6505**Diagnostic text:**
6506
6507+---------------------------------------------------------------------------------------------------------------+
6508|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has virtual functions but non-virtual destructor`|
6509+---------------------------------------------------------------------------------------------------------------+
6510
6511
6512-Wnonnull
6513---------
6514This diagnostic is enabled by default.
6515
6516**Diagnostic text:**
6517
6518+------------------------------------------------------------------------------------------------+
6519|:warning:`warning:` |nbsp| :diagtext:`null passed to a callee that requires a non-null argument`|
6520+------------------------------------------------------------------------------------------------+
6521
6522+-----------------------------------------------------------------+----------------------+---------------------------------------------------------+
6523|:warning:`warning:` |nbsp| :diagtext:`null returned from` |nbsp| |+--------------------+| |nbsp| :diagtext:`that requires a non-null return value`|
6524| ||:diagtext:`function`|| |
6525| |+--------------------+| |
6526| ||:diagtext:`method` || |
6527| |+--------------------+| |
6528+-----------------------------------------------------------------+----------------------+---------------------------------------------------------+
6529
6530
6531-Wnonportable-cfstrings
6532-----------------------
6533This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
6534
6535-Wnonportable-include-path
6536--------------------------
6537This diagnostic is enabled by default.
6538
6539**Diagnostic text:**
6540
6541+------------------------------------------------------------------------------------------------------------------------------------------------------+
6542|:warning:`warning:` |nbsp| :diagtext:`non-portable path to file '`:placeholder:`A`:diagtext:`'; specified path differs in case from file name on disk`|
6543+------------------------------------------------------------------------------------------------------------------------------------------------------+
6544
6545
6546-Wnonportable-system-include-path
6547---------------------------------
6548**Diagnostic text:**
6549
6550+------------------------------------------------------------------------------------------------------------------------------------------------------+
6551|:warning:`warning:` |nbsp| :diagtext:`non-portable path to file '`:placeholder:`A`:diagtext:`'; specified path differs in case from file name on disk`|
6552+------------------------------------------------------------------------------------------------------------------------------------------------------+
6553
6554
6555-Wnonportable-vector-initialization
6556-----------------------------------
6557This diagnostic is enabled by default.
6558
6559**Diagnostic text:**
6560
6561+---------------------------------------------------------------------------------------------------------------------+
6562|:warning:`warning:` |nbsp| :diagtext:`vector initializers are not compatible with NEON intrinsics in big endian mode`|
6563+---------------------------------------------------------------------------------------------------------------------+
6564
6565
6566-Wnull-arithmetic
6567-----------------
6568This diagnostic is enabled by default.
6569
6570**Diagnostic text:**
6571
6572+--------------------------------------------------------------------------+
6573|:warning:`warning:` |nbsp| :diagtext:`use of NULL in arithmetic operation`|
6574+--------------------------------------------------------------------------+
6575
6576+--------------------------------------------------------------------------------------+--------------------------------------------------------------+
6577|:warning:`warning:` |nbsp| :diagtext:`comparison between NULL and non-pointer` |nbsp| |+------------------------------------------------------------+|
6578| ||+----------------------------------------------------------+||
6579| |||:diagtext:`(`:placeholder:`B` |nbsp| :diagtext:`and NULL)`|||
6580| ||+----------------------------------------------------------+||
6581| |+------------------------------------------------------------+|
6582| ||+----------------------------------------------------------+||
6583| |||:diagtext:`(NULL and` |nbsp| :placeholder:`B`:diagtext:`)`|||
6584| ||+----------------------------------------------------------+||
6585| |+------------------------------------------------------------+|
6586+--------------------------------------------------------------------------------------+--------------------------------------------------------------+
6587
6588
6589-Wnull-character
6590----------------
6591This diagnostic is enabled by default.
6592
6593**Diagnostic text:**
6594
6595+-----------------------------------------------------------------------------+--------------------+---------------------------+
6596|:warning:`warning:` |nbsp| :diagtext:`null character(s) preserved in` |nbsp| |+------------------+| |nbsp| :diagtext:`literal`|
6597| ||:diagtext:`char` || |
6598| |+------------------+| |
6599| ||:diagtext:`string`|| |
6600| |+------------------+| |
6601+-----------------------------------------------------------------------------+--------------------+---------------------------+
6602
6603+-------------------------------------------------------------+
6604|:warning:`warning:` |nbsp| :diagtext:`null character ignored`|
6605+-------------------------------------------------------------+
6606
6607
6608-Wnull-conversion
6609-----------------
6610This diagnostic is enabled by default.
6611
6612**Diagnostic text:**
6613
6614+---------------------------------------------------------------------+---------------------+-------------------------------------------------------+
6615|:warning:`warning:` |nbsp| :diagtext:`implicit conversion of` |nbsp| |+-------------------+| |nbsp| :diagtext:`constant to` |nbsp| :placeholder:`B`|
6616| ||:diagtext:`NULL` || |
6617| |+-------------------+| |
6618| ||:diagtext:`nullptr`|| |
6619| |+-------------------+| |
6620+---------------------------------------------------------------------+---------------------+-------------------------------------------------------+
6621
6622
6623-Wnull-dereference
6624------------------
6625This diagnostic is enabled by default.
6626
6627**Diagnostic text:**
6628
6629+------------------------------------------------------------------------------------------------------------+
6630|:warning:`warning:` |nbsp| :diagtext:`binding dereferenced null pointer to reference has undefined behavior`|
6631+------------------------------------------------------------------------------------------------------------+
6632
6633+---------------------------------------------------------------------------------------------------------+
6634|:warning:`warning:` |nbsp| :diagtext:`indirection of non-volatile null pointer will be deleted, not trap`|
6635+---------------------------------------------------------------------------------------------------------+
6636
6637
6638-Wnullability
6639-------------
6640This diagnostic is enabled by default.
6641
6642**Diagnostic text:**
6643
6644+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6645|:warning:`warning:` |nbsp| :diagtext:`conflicting nullability specifier on parameter types,` |nbsp| :placeholder:`A` |nbsp| :diagtext:`conflicts with existing specifier` |nbsp| :placeholder:`B`|
6646+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6647
6648+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6649|:warning:`warning:` |nbsp| :diagtext:`conflicting nullability specifier on return types,` |nbsp| :placeholder:`A` |nbsp| :diagtext:`conflicts with existing specifier` |nbsp| :placeholder:`B`|
6650+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6651
6652+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
6653|:warning:`warning:` |nbsp| :diagtext:`nullability specifier` |nbsp| :placeholder:`A` |nbsp| :diagtext:`conflicts with existing specifier` |nbsp| :placeholder:`B`|
6654+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
6655
6656+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6657|:warning:`warning:` |nbsp| :diagtext:`synthesized setter` |nbsp| :placeholder:`A` |nbsp| :diagtext:`for null\_resettable property` |nbsp| :placeholder:`B` |nbsp| :diagtext:`does not handle nil`|
6658+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6659
6660+----------------------------------------------------------------------------------------------+
6661|:warning:`warning:` |nbsp| :diagtext:`duplicate nullability specifier` |nbsp| :placeholder:`A`|
6662+----------------------------------------------------------------------------------------------+
6663
6664
6665-Wnullability-completeness
6666--------------------------
6667This diagnostic is enabled by default.
6668
6669**Diagnostic text:**
6670
6671+---------------------------+----------------------------+-----------------------------------------------------------------------------------------------------------+
6672|:warning:`warning:` |nbsp| |+--------------------------+| |nbsp| :diagtext:`is missing a nullability type specifier (\_Nonnull, \_Nullable, or \_Null\_unspecified)`|
6673| ||:diagtext:`pointer` || |
6674| |+--------------------------+| |
6675| ||:diagtext:`block pointer` || |
6676| |+--------------------------+| |
6677| ||:diagtext:`member pointer`|| |
6678| |+--------------------------+| |
6679+---------------------------+----------------------------+-----------------------------------------------------------------------------------------------------------+
6680
6681
6682-Wnullability-declspec
6683----------------------
6684This diagnostic is an error by default, but the flag ``-Wno-nullability-declspec`` can be used to disable the error.
6685
6686**Diagnostic text:**
6687
6688+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------+-------------+
6689|:error:`error:` |nbsp| :diagtext:`nullability specifier` |nbsp| :placeholder:`A` |nbsp| :diagtext:`cannot be applied to non-pointer type` |nbsp| :placeholder:`B`:diagtext:`; did you mean to apply the specifier to the` |nbsp| |+-----------------------------------+|:diagtext:`?`|
6690| ||:diagtext:`pointer` || |
6691| |+-----------------------------------+| |
6692| ||:diagtext:`block pointer` || |
6693| |+-----------------------------------+| |
6694| ||:diagtext:`member pointer` || |
6695| |+-----------------------------------+| |
6696| ||:diagtext:`function pointer` || |
6697| |+-----------------------------------+| |
6698| ||:diagtext:`member function pointer`|| |
6699| |+-----------------------------------+| |
6700+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------+-------------+
6701
6702
6703-Wnullability-extension
6704-----------------------
6705**Diagnostic text:**
6706
6707+---------------------------------------------------------------------------------------------------------------------------------+
6708|:warning:`warning:` |nbsp| :diagtext:`type nullability specifier` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a Clang extension`|
6709+---------------------------------------------------------------------------------------------------------------------------------+
6710
6711
6712-Wnullable-to-nonnull-conversion
6713--------------------------------
6714**Diagnostic text:**
6715
6716+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6717|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from nullable pointer` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to non-nullable pointer type` |nbsp| :placeholder:`B`|
6718+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6719
6720
6721-Wobjc-autosynthesis-property-ivar-name-match
6722---------------------------------------------
6723This diagnostic is enabled by default.
6724
6725**Diagnostic text:**
6726
6727+---------------------------------------------------------------------------------------------------------------------------+-------------------------+---------------------------------------------------------------------------------------------------------------------------------+
6728|:warning:`warning:` |nbsp| :diagtext:`autosynthesized property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will use` |nbsp| |+-----------------------+| |nbsp| :diagtext:`instance variable` |nbsp| :placeholder:`C`:diagtext:`, not existing instance variable` |nbsp| :placeholder:`D`|
6729| || || |
6730| |+-----------------------+| |
6731| ||:diagtext:`synthesized`|| |
6732| |+-----------------------+| |
6733+---------------------------------------------------------------------------------------------------------------------------+-------------------------+---------------------------------------------------------------------------------------------------------------------------------+
6734
6735
6736-Wobjc-circular-container
6737-------------------------
6738This diagnostic is enabled by default.
6739
6740**Diagnostic text:**
6741
6742+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
6743|:warning:`warning:` |nbsp| :diagtext:`adding '`:placeholder:`A`:diagtext:`' to '`:placeholder:`B`:diagtext:`' might cause circular dependency in container`|
6744+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
6745
6746
6747-Wobjc-cocoa-api
6748----------------
6749Synonym for `-Wobjc-redundant-api-use`_.
6750
6751
6752-Wobjc-designated-initializers
6753------------------------------
6754This diagnostic is enabled by default.
6755
6756**Diagnostic text:**
6757
6758+-----------------------------------------------------------------------------------------------------------------------------------+
6759|:warning:`warning:` |nbsp| :diagtext:`designated initializer missing a 'super' call to a designated initializer of the super class`|
6760+-----------------------------------------------------------------------------------------------------------------------------------+
6761
6762+--------------------------------------------------------------------------------------------------+
6763|:warning:`warning:` |nbsp| :diagtext:`designated initializer invoked a non-designated initializer`|
6764+--------------------------------------------------------------------------------------------------+
6765
6766+--------------------------------------------------------------------------------------------------------------------+
6767|:warning:`warning:` |nbsp| :diagtext:`designated initializer should only invoke a designated initializer on 'super'`|
6768+--------------------------------------------------------------------------------------------------------------------+
6769
6770+------------------------------------------------------------------------------------------------------------------------------------------------------------+
6771|:warning:`warning:` |nbsp| :diagtext:`method override for the designated initializer of the superclass` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found`|
6772+------------------------------------------------------------------------------------------------------------------------------------------------------------+
6773
6774+-----------------------------------------------------------------------------------------------------------+
6775|:warning:`warning:` |nbsp| :diagtext:`convenience initializer missing a 'self' call to another initializer`|
6776+-----------------------------------------------------------------------------------------------------------+
6777
6778+----------------------------------------------------------------------------------------------------------+
6779|:warning:`warning:` |nbsp| :diagtext:`convenience initializer should not invoke an initializer on 'super'`|
6780+----------------------------------------------------------------------------------------------------------+
6781
6782
6783-Wobjc-forward-class-redefinition
6784---------------------------------
6785This diagnostic is enabled by default.
6786
6787**Diagnostic text:**
6788
6789+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
6790|:warning:`warning:` |nbsp| :diagtext:`redefinition of forward class` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of a typedef name of an object type is ignored`|
6791+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
6792
6793
6794-Wobjc-interface-ivars
6795----------------------
6796**Diagnostic text:**
6797
6798+-------------------------------------------------------------------------------------------------------+
6799|:warning:`warning:` |nbsp| :diagtext:`declaration of instance variables in the interface is deprecated`|
6800+-------------------------------------------------------------------------------------------------------+
6801
6802
6803-Wobjc-literal-compare
6804----------------------
6805This diagnostic is enabled by default.
6806
6807Also controls `-Wobjc-string-compare`_.
6808
6809**Diagnostic text:**
6810
6811+-------------------------------------------------------------------+----------------------------------+------------------------------------------+
6812|:warning:`warning:` |nbsp| :diagtext:`direct comparison of` |nbsp| |+--------------------------------+| |nbsp| :diagtext:`has undefined behavior`|
6813| ||:diagtext:`an array literal` || |
6814| |+--------------------------------+| |
6815| ||:diagtext:`a dictionary literal`|| |
6816| |+--------------------------------+| |
6817| ||:diagtext:`a numeric literal` || |
6818| |+--------------------------------+| |
6819| ||:diagtext:`a boxed expression` || |
6820| |+--------------------------------+| |
6821| || || |
6822| |+--------------------------------+| |
6823+-------------------------------------------------------------------+----------------------------------+------------------------------------------+
6824
6825
6826-Wobjc-literal-conversion
6827-------------------------
6828This diagnostic is enabled by default.
6829
6830**Diagnostic text:**
6831
6832+-------------------------------------------------------------------------------------------------------------------------+
6833|:warning:`warning:` |nbsp| :diagtext:`implicit boolean conversion of Objective-C object literal always evaluates to true`|
6834+-------------------------------------------------------------------------------------------------------------------------+
6835
6836+-------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------+
6837|:warning:`warning:` |nbsp| :diagtext:`object of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not compatible with` |nbsp| |+---------------------------------+| |nbsp| :placeholder:`C`|
6838| ||:diagtext:`array element type` || |
6839| |+---------------------------------+| |
6840| ||:diagtext:`dictionary key type` || |
6841| |+---------------------------------+| |
6842| ||:diagtext:`dictionary value type`|| |
6843| |+---------------------------------+| |
6844+-------------------------------------------------------------------------------------------------------------------------------+-----------------------------------+------------------------+
6845
6846
6847-Wobjc-macro-redefinition
6848-------------------------
6849This diagnostic is enabled by default.
6850
6851**Diagnostic text:**
6852
6853+-------------------------------------------------------------------------------------------+
6854|:warning:`warning:` |nbsp| :diagtext:`ignoring redefinition of Objective-C qualifier macro`|
6855+-------------------------------------------------------------------------------------------+
6856
6857
6858-Wobjc-method-access
6859--------------------
6860This diagnostic is enabled by default.
6861
6862**Diagnostic text:**
6863
6864+---------------------------------------------------------------------------------------------------------------------------------------+
6865|:warning:`warning:` |nbsp| :diagtext:`class method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found (return type defaults to 'id')`|
6866+---------------------------------------------------------------------------------------------------------------------------------------+
6867
6868+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6869|:warning:`warning:` |nbsp| :diagtext:`class method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found (return type defaults to 'id'); did you mean` |nbsp| :placeholder:`C`:diagtext:`?`|
6870+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6871
6872+------------------------------------------------------------------------------------------------------------------------------------------+
6873|:warning:`warning:` |nbsp| :diagtext:`instance method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found (return type defaults to 'id')`|
6874+------------------------------------------------------------------------------------------------------------------------------------------+
6875
6876+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6877|:warning:`warning:` |nbsp| :diagtext:`instance method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found (return type defaults to 'id'); did you mean` |nbsp| :placeholder:`C`:diagtext:`?`|
6878+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6879
6880+-------------------------------------------------------------------------------------------------------------------------------------------------------+
6881|:warning:`warning:` |nbsp| :diagtext:`instance method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`found instead of class method` |nbsp| :placeholder:`B`|
6882+-------------------------------------------------------------------------------------------------------------------------------------------------------+
6883
6884+---------------------------------------------------------------------------------------------------------------------------------------------------------+
6885|:warning:`warning:` |nbsp| :diagtext:`instance method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is being used on 'Class' which is not in the root class`|
6886+---------------------------------------------------------------------------------------------------------------------------------------------------------+
6887
6888
6889-Wobjc-missing-property-synthesis
6890---------------------------------
6891**Diagnostic text:**
6892
6893+------------------------------------------------------------------------------------------------------------------+
6894|:warning:`warning:` |nbsp| :diagtext:`auto property synthesis is synthesizing property not explicitly synthesized`|
6895+------------------------------------------------------------------------------------------------------------------+
6896
6897
6898-Wobjc-missing-super-calls
6899--------------------------
6900This diagnostic is enabled by default.
6901
6902**Diagnostic text:**
6903
6904+-------------------------------------------------------------------------------------------------------------------+
6905|:warning:`warning:` |nbsp| :diagtext:`method possibly missing a \[super` |nbsp| :placeholder:`A`:diagtext:`\] call`|
6906+-------------------------------------------------------------------------------------------------------------------+
6907
6908
6909-Wobjc-multiple-method-names
6910----------------------------
6911This diagnostic is enabled by default.
6912
6913**Diagnostic text:**
6914
6915+--------------------------------------------------------------------------------------------------------------+
6916|:warning:`warning:` |nbsp| :diagtext:`multiple methods named` |nbsp| :placeholder:`A` |nbsp| :diagtext:`found`|
6917+--------------------------------------------------------------------------------------------------------------+
6918
6919
6920-Wobjc-noncopy-retain-block-property
6921------------------------------------
6922This diagnostic is enabled by default.
6923
6924**Diagnostic text:**
6925
6926+--------------------------------------------------------------------------------------------------------------------+
6927|:warning:`warning:` |nbsp| :diagtext:`retain'ed block property does not copy the block - use copy attribute instead`|
6928+--------------------------------------------------------------------------------------------------------------------+
6929
6930
6931-Wobjc-nonunified-exceptions
6932----------------------------
6933This diagnostic is enabled by default.
6934
6935**Diagnostic text:**
6936
6937+-----------------------------------------------------------------------------------------------------------------------------+
6938|:warning:`warning:` |nbsp| :diagtext:`cannot catch an exception thrown with @throw in C++ in the non-unified exception model`|
6939+-----------------------------------------------------------------------------------------------------------------------------+
6940
6941
6942-Wobjc-property-implementation
6943------------------------------
6944This diagnostic is enabled by default.
6945
6946**Diagnostic text:**
6947
6948+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6949|:warning:`warning:` |nbsp| :diagtext:`class property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires method` |nbsp| :placeholder:`B` |nbsp| :diagtext:`to be defined - use @dynamic or provide a method implementation in this class implementation`|
6950+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6951
6952+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6953|:warning:`warning:` |nbsp| :diagtext:`class property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires method` |nbsp| :placeholder:`B` |nbsp| :diagtext:`to be defined - use @dynamic or provide a method implementation in this category`|
6954+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6955
6956+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6957|:warning:`warning:` |nbsp| :diagtext:`property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires method` |nbsp| :placeholder:`B` |nbsp| :diagtext:`to be defined - use @synthesize, @dynamic or provide a method implementation in this class implementation`|
6958+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6959
6960+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6961|:warning:`warning:` |nbsp| :diagtext:`property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires method` |nbsp| :placeholder:`B` |nbsp| :diagtext:`to be defined - use @dynamic or provide a method implementation in this category`|
6962+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
6963
6964
6965-Wobjc-property-implicit-mismatch
6966---------------------------------
6967This diagnostic is enabled by default.
6968
6969**Diagnostic text:**
6970
6971+---------------------------------------------------------------------------------------------------------------------------------------+
6972|:warning:`warning:` |nbsp| :diagtext:`primary property declaration is implicitly strong while redeclaration in class extension is weak`|
6973+---------------------------------------------------------------------------------------------------------------------------------------+
6974
6975
6976-Wobjc-property-matches-cocoa-ownership-rule
6977--------------------------------------------
6978This diagnostic is enabled by default.
6979
6980**Diagnostic text:**
6981
6982+-------------------------------------------------------------------------------------------------------------+
6983|:warning:`warning:` |nbsp| :diagtext:`property follows Cocoa naming convention for returning 'owned' objects`|
6984+-------------------------------------------------------------------------------------------------------------+
6985
6986
6987-Wobjc-property-no-attribute
6988----------------------------
6989This diagnostic is enabled by default.
6990
6991**Diagnostic text:**
6992
6993+------------------------------------------------------------------------------------------------------------+
6994|:warning:`warning:` |nbsp| :diagtext:`default property attribute 'assign' not appropriate for non-GC object`|
6995+------------------------------------------------------------------------------------------------------------+
6996
6997+--------------------------------------------------------------------------------------------------------------------+
6998|:warning:`warning:` |nbsp| :diagtext:`no 'assign', 'retain', or 'copy' attribute is specified - 'assign' is assumed`|
6999+--------------------------------------------------------------------------------------------------------------------+
7000
7001
7002-Wobjc-property-synthesis
7003-------------------------
7004This diagnostic is enabled by default.
7005
7006**Diagnostic text:**
7007
7008+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7009|:warning:`warning:` |nbsp| :diagtext:`auto property synthesis will not synthesize property` |nbsp| :placeholder:`A`:diagtext:`; it will be implemented by its superclass, use @dynamic to acknowledge intention`|
7010+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7011
7012+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7013|:warning:`warning:` |nbsp| :diagtext:`auto property synthesis will not synthesize property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`because it is 'readwrite' but it will be synthesized 'readonly' via another property`|
7014+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7015
7016+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7017|:warning:`warning:` |nbsp| :diagtext:`auto property synthesis will not synthesize property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`because it cannot share an ivar with another synthesized property`|
7018+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7019
7020
7021-Wobjc-protocol-method-implementation
7022-------------------------------------
7023This diagnostic is enabled by default.
7024
7025**Diagnostic text:**
7026
7027+----------------------------------------------------------------------------------------------------------------------------+
7028|:warning:`warning:` |nbsp| :diagtext:`category is implementing a method which will also be implemented by its primary class`|
7029+----------------------------------------------------------------------------------------------------------------------------+
7030
7031
7032-Wobjc-protocol-property-synthesis
7033----------------------------------
7034This diagnostic is enabled by default.
7035
7036**Diagnostic text:**
7037
7038+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7039|:warning:`warning:` |nbsp| :diagtext:`auto property synthesis will not synthesize property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`declared in protocol` |nbsp| :placeholder:`B`|
7040+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7041
7042
7043-Wobjc-protocol-qualifiers
7044--------------------------
7045This diagnostic is enabled by default.
7046
7047**Diagnostic text:**
7048
7049+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7050|:warning:`warning:` |nbsp| :diagtext:`parameterized class` |nbsp| :placeholder:`A` |nbsp| :diagtext:`already conforms to the protocols listed; did you forget a '\*'?`|
7051+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7052
7053
7054-Wobjc-readonly-with-setter-property
7055------------------------------------
7056This diagnostic is enabled by default.
7057
7058**Diagnostic text:**
7059
7060+-----------------------------------------------------------------------------------------+
7061|:warning:`warning:` |nbsp| :diagtext:`setter cannot be specified for a readonly property`|
7062+-----------------------------------------------------------------------------------------+
7063
7064
7065-Wobjc-redundant-api-use
7066------------------------
7067Synonym for `-Wobjc-redundant-literal-use`_.
7068
7069
7070-Wobjc-redundant-literal-use
7071----------------------------
7072This diagnostic is enabled by default.
7073
7074**Diagnostic text:**
7075
7076+-------------------------------------------------------------------------------------------------------------------+
7077|:warning:`warning:` |nbsp| :diagtext:`using` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with a literal is redundant`|
7078+-------------------------------------------------------------------------------------------------------------------+
7079
7080
7081-Wobjc-root-class
7082-----------------
7083This diagnostic is enabled by default.
7084
7085**Diagnostic text:**
7086
7087+-------------------------------------------------------------------------------------------------------------------------------+
7088|:warning:`warning:` |nbsp| :diagtext:`class` |nbsp| :placeholder:`A` |nbsp| :diagtext:`defined without specifying a base class`|
7089+-------------------------------------------------------------------------------------------------------------------------------+
7090
7091
7092-Wobjc-string-compare
7093---------------------
7094This diagnostic is enabled by default.
7095
7096**Diagnostic text:**
7097
7098+---------------------------------------------------------------------------------------------------+
7099|:warning:`warning:` |nbsp| :diagtext:`direct comparison of a string literal has undefined behavior`|
7100+---------------------------------------------------------------------------------------------------+
7101
7102
7103-Wobjc-string-concatenation
7104---------------------------
7105This diagnostic is enabled by default.
7106
7107**Diagnostic text:**
7108
7109+-------------------------------------------------------------------------------------------------------------------------+
7110|:warning:`warning:` |nbsp| :diagtext:`concatenated NSString literal for an NSArray expression - possibly missing a comma`|
7111+-------------------------------------------------------------------------------------------------------------------------+
7112
7113
7114-Wodr
7115-----
7116This diagnostic is enabled by default.
7117
7118**Diagnostic text:**
7119
7120+--------------------------------------------------------------------------------------------------------------------------------------------------+
7121|:warning:`warning:` |nbsp| :diagtext:`type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has incompatible definitions in different translation units`|
7122+--------------------------------------------------------------------------------------------------------------------------------------------------+
7123
7124
7125-Wold-style-cast
7126----------------
7127**Diagnostic text:**
7128
7129+------------------------------------------------------------+
7130|:warning:`warning:` |nbsp| :diagtext:`use of old-style cast`|
7131+------------------------------------------------------------+
7132
7133
7134-Wold-style-definition
7135----------------------
7136This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
7137
7138-Wopencl-unsupported-rgba
7139-------------------------
7140This diagnostic is enabled by default.
7141
7142**Diagnostic text:**
7143
7144+----------------------------------------------------------------------------------------------------------------------------+
7145|:warning:`warning:` |nbsp| :diagtext:`vector component name '`:placeholder:`A`:diagtext:`' is an OpenCL version 2.2 feature`|
7146+----------------------------------------------------------------------------------------------------------------------------+
7147
7148
7149-Wopenmp-clauses
7150----------------
7151This diagnostic is enabled by default.
7152
7153**Diagnostic text:**
7154
7155+-------------------------------------------------------------------------------------------------------------------------+
7156|:warning:`warning:` |nbsp| :diagtext:`aligned clause will be ignored because the requested alignment is not a power of 2`|
7157+-------------------------------------------------------------------------------------------------------------------------+
7158
7159+---------------------------------------------------------------------------------+---------------------------------------------------+-------------------------------------+
7160|:warning:`warning:` |nbsp| :diagtext:`zero linear step (`:placeholder:`A` |nbsp| |+-------------------------------------------------+|:diagtext:`should probably be const)`|
7161| || || |
7162| |+-------------------------------------------------+| |
7163| ||:diagtext:`and other variables in clause` |nbsp| || |
7164| |+-------------------------------------------------+| |
7165+---------------------------------------------------------------------------------+---------------------------------------------------+-------------------------------------+
7166
7167
7168-Wopenmp-loop-form
7169------------------
7170This diagnostic is enabled by default.
7171
7172**Diagnostic text:**
7173
7174+-----------------------------------------------------------------------------------------------------------------------------------------+
7175|:warning:`warning:` |nbsp| :diagtext:`initialization clause of OpenMP for loop is not in canonical form ('var = init' or 'T var = init')`|
7176+-----------------------------------------------------------------------------------------------------------------------------------------+
7177
7178+-----------------------------------------------------------------------------------------------------------------------------+
7179|:warning:`warning:` |nbsp| :diagtext:`OpenMP loop iteration variable cannot have more than 64 bits size and will be narrowed`|
7180+-----------------------------------------------------------------------------------------------------------------------------+
7181
7182
7183-Wopenmp-target
7184---------------
7185This diagnostic is enabled by default.
7186
7187**Diagnostic text:**
7188
7189+-----------------------------------------------------------------------------------------------+
7190|:warning:`warning:` |nbsp| :diagtext:`declaration is not declared in any declare target region`|
7191+-----------------------------------------------------------------------------------------------+
7192
7193
7194-Woption-ignored
7195----------------
7196This diagnostic is enabled by default.
7197
7198**Diagnostic text:**
7199
7200+----------------------------------------------------------------------------------------------------------------------------+
7201|:warning:`warning:` |nbsp| :diagtext:`option '`:placeholder:`A`:diagtext:`' was ignored by the PS4 toolchain, using '-fPIC'`|
7202+----------------------------------------------------------------------------------------------------------------------------+
7203
7204
7205-Wout-of-line-declaration
7206-------------------------
7207This diagnostic is an error by default, but the flag ``-Wno-out-of-line-declaration`` can be used to disable the error.
7208
7209**Diagnostic text:**
7210
7211+-------------------------------------------------------------------------------------------+
7212|:error:`error:` |nbsp| :diagtext:`out-of-line declaration of a member must be a definition`|
7213+-------------------------------------------------------------------------------------------+
7214
7215
7216-Wover-aligned
7217--------------
7218**Diagnostic text:**
7219
7220+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7221|:warning:`warning:` |nbsp| :diagtext:`type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires` |nbsp| :placeholder:`B` |nbsp| :diagtext:`bytes of alignment and the default allocator only guarantees` |nbsp| :placeholder:`C` |nbsp| :diagtext:`bytes`|
7222+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7223
7224
7225-Woverflow
7226----------
7227This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
7228
7229-Woverlength-strings
7230--------------------
7231**Diagnostic text:**
7232
7233+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------+
7234|:warning:`warning:` |nbsp| :diagtext:`string literal of length` |nbsp| :placeholder:`A` |nbsp| :diagtext:`exceeds maximum length` |nbsp| :placeholder:`B` |nbsp| :diagtext:`that` |nbsp| |+-------------------+| |nbsp| :diagtext:`compilers are required to support`|
7235| ||:diagtext:`C90` || |
7236| |+-------------------+| |
7237| ||:diagtext:`ISO C99`|| |
7238| |+-------------------+| |
7239| ||:diagtext:`C++` || |
7240| |+-------------------+| |
7241+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------+
7242
7243
7244-Woverloaded-shift-op-parentheses
7245---------------------------------
7246This diagnostic is enabled by default.
7247
7248**Diagnostic text:**
7249
7250+------------------------------------------------------------------+----------------+------------------------------------------------------------------+
7251|:warning:`warning:` |nbsp| :diagtext:`overloaded operator` |nbsp| |+--------------+| |nbsp| :diagtext:`has higher precedence than comparison operator`|
7252| ||:diagtext:`>>`|| |
7253| |+--------------+| |
7254| ||:diagtext:`<<`|| |
7255| |+--------------+| |
7256+------------------------------------------------------------------+----------------+------------------------------------------------------------------+
7257
7258
7259-Woverloaded-virtual
7260--------------------
7261**Diagnostic text:**
7262
7263+-----------------------------------------------------------------------------------------------+-----------------------+
7264|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`hides overloaded virtual` |nbsp| |+---------------------+|
7265| ||:diagtext:`function` ||
7266| |+---------------------+|
7267| ||:diagtext:`functions`||
7268| |+---------------------+|
7269+-----------------------------------------------------------------------------------------------+-----------------------+
7270
7271
7272-Woverride-module
7273-----------------
7274This diagnostic is enabled by default.
7275
7276**Diagnostic text:**
7277
7278+-------------------------------------------------------------------------------------------------------+
7279|:warning:`warning:` |nbsp| :diagtext:`overriding the module target triple with` |nbsp| :placeholder:`A`|
7280+-------------------------------------------------------------------------------------------------------+
7281
7282
7283-Woverriding-method-mismatch
7284----------------------------
7285**Diagnostic text:**
7286
7287+-------------------------------------------------------------------------------------------------------------------------------------------+
7288|:warning:`warning:` |nbsp| :diagtext:`conflicting distributed object modifiers on parameter type in declaration of` |nbsp| :placeholder:`A`|
7289+-------------------------------------------------------------------------------------------------------------------------------------------+
7290
7291+------------------------------------------------------------------------------------------------------------+
7292|:warning:`warning:` |nbsp| :diagtext:`conflicting parameter types in declaration of` |nbsp| :placeholder:`A`|
7293+------------------------------------------------------------------------------------------------------------+
7294
7295+----------------------------------------------------------------------------------------------------------------------------------------+
7296|:warning:`warning:` |nbsp| :diagtext:`conflicting distributed object modifiers on return type in declaration of` |nbsp| :placeholder:`A`|
7297+----------------------------------------------------------------------------------------------------------------------------------------+
7298
7299+--------------------------------------------------------------------------------------------------------+
7300|:warning:`warning:` |nbsp| :diagtext:`conflicting return type in declaration of` |nbsp| :placeholder:`A`|
7301+--------------------------------------------------------------------------------------------------------+
7302
7303+--------------------------------------------------------------------------------------------------------+
7304|:warning:`warning:` |nbsp| :diagtext:`conflicting variadic declaration of method and its implementation`|
7305+--------------------------------------------------------------------------------------------------------+
7306
7307+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7308|:warning:`warning:` |nbsp| :diagtext:`conflicting parameter types in declaration of` |nbsp| :placeholder:`A`:diagtext:`:` |nbsp| :placeholder:`B` |nbsp| :diagtext:`vs` |nbsp| :placeholder:`C`|
7309+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7310
7311+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7312|:warning:`warning:` |nbsp| :diagtext:`conflicting return type in declaration of` |nbsp| :placeholder:`A`:diagtext:`:` |nbsp| :placeholder:`B` |nbsp| :diagtext:`vs` |nbsp| :placeholder:`C`|
7313+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7314
7315
7316-Woverriding-t-option
7317---------------------
7318This diagnostic is enabled by default.
7319
7320**Diagnostic text:**
7321
7322+---------------------------------------------------------------------------------------------------------------------------+
7323|:warning:`warning:` |nbsp| :diagtext:`overriding '`:placeholder:`A`:diagtext:`' option with '`:placeholder:`B`:diagtext:`'`|
7324+---------------------------------------------------------------------------------------------------------------------------+
7325
7326
7327-Wpacked
7328--------
7329**Diagnostic text:**
7330
7331+--------------------------------------------------------------------------------------------------+
7332|:warning:`warning:` |nbsp| :diagtext:`packed attribute is unnecessary for` |nbsp| :placeholder:`A`|
7333+--------------------------------------------------------------------------------------------------+
7334
7335
7336-Wpadded
7337--------
7338**Diagnostic text:**
7339
7340+------------------------------------------------------+-----------------------+--------------------------------------------------------------------------------+------------------+---------------+------------------------------------------------+
7341|:warning:`warning:` |nbsp| :diagtext:`padding` |nbsp| |+---------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`with` |nbsp| :placeholder:`C` |nbsp| |+----------------+|+-------------+| |nbsp| :diagtext:`to align anonymous bit-field`|
7342| ||:diagtext:`struct` || ||:diagtext:`byte`||| || |
7343| |+---------------------+| |+----------------+|+-------------+| |
7344| ||:diagtext:`interface`|| ||:diagtext:`bit` |||:diagtext:`s`|| |
7345| |+---------------------+| |+----------------+|+-------------+| |
7346| ||:diagtext:`class` || | | | |
7347| |+---------------------+| | | | |
7348+------------------------------------------------------+-----------------------+--------------------------------------------------------------------------------+------------------+---------------+------------------------------------------------+
7349
7350+------------------------------------------------------+-----------------------+--------------------------------------------------------------------------------+------------------+---------------+----------------------------------------------------+
7351|:warning:`warning:` |nbsp| :diagtext:`padding` |nbsp| |+---------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`with` |nbsp| :placeholder:`C` |nbsp| |+----------------+|+-------------+| |nbsp| :diagtext:`to align` |nbsp| :placeholder:`E`|
7352| ||:diagtext:`struct` || ||:diagtext:`byte`||| || |
7353| |+---------------------+| |+----------------+|+-------------+| |
7354| ||:diagtext:`interface`|| ||:diagtext:`bit` |||:diagtext:`s`|| |
7355| |+---------------------+| |+----------------+|+-------------+| |
7356| ||:diagtext:`class` || | | | |
7357| |+---------------------+| | | | |
7358+------------------------------------------------------+-----------------------+--------------------------------------------------------------------------------+------------------+---------------+----------------------------------------------------+
7359
7360+--------------------------------------------------------------------------------------------------------------------------------------+------------------+---------------+-----------------------------------------+
7361|:warning:`warning:` |nbsp| :diagtext:`padding size of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`with` |nbsp| :placeholder:`B` |nbsp| |+----------------+|+-------------+| |nbsp| :diagtext:`to alignment boundary`|
7362| ||:diagtext:`byte`||| || |
7363| |+----------------+|+-------------+| |
7364| ||:diagtext:`bit` |||:diagtext:`s`|| |
7365| |+----------------+|+-------------+| |
7366+--------------------------------------------------------------------------------------------------------------------------------------+------------------+---------------+-----------------------------------------+
7367
7368
7369-Wparentheses
7370-------------
7371This diagnostic is enabled by default.
7372
7373Also controls `-Wlogical-op-parentheses`_, `-Wlogical-not-parentheses`_, `-Wbitwise-op-parentheses`_, `-Wshift-op-parentheses`_, `-Woverloaded-shift-op-parentheses`_, `-Wparentheses-equality`_, `-Wdangling-else`_.
7374
7375**Diagnostic text:**
7376
7377+-----------------------------------------------------------------------------------------------------------+
7378|:warning:`warning:` |nbsp| :diagtext:`using the result of an assignment as a condition without parentheses`|
7379+-----------------------------------------------------------------------------------------------------------+
7380
7381+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7382|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has lower precedence than` |nbsp| :placeholder:`B`:diagtext:`;` |nbsp| :placeholder:`B` |nbsp| :diagtext:`will be evaluated first`|
7383+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7384
7385+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7386|:warning:`warning:` |nbsp| :diagtext:`operator '?:' has lower precedence than '`:placeholder:`A`:diagtext:`'; '`:placeholder:`A`:diagtext:`' will be evaluated first`|
7387+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7388
7389
7390-Wparentheses-equality
7391----------------------
7392This diagnostic is enabled by default.
7393
7394**Diagnostic text:**
7395
7396+--------------------------------------------------------------------------------------+
7397|:warning:`warning:` |nbsp| :diagtext:`equality comparison with extraneous parentheses`|
7398+--------------------------------------------------------------------------------------+
7399
7400
7401-Wpartial-availability
7402----------------------
7403Synonym for `-Wunguarded-availability`_.
7404
7405
7406-Rpass
7407------
7408**Diagnostic text:**
7409
7410The text of this diagnostic is not controlled by Clang.
7411
7412
7413-Rpass-analysis
7414---------------
7415**Diagnostic text:**
7416
7417The text of this diagnostic is not controlled by Clang.
7418
7419+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7420|:remark:`remark:` |nbsp| :placeholder:`A`:diagtext:`; allow reordering by specifying '#pragma clang loop vectorize(enable)' before the loop. If the arrays will always be independent specify '#pragma clang loop vectorize(assume\_safety)' before the loop or provide the '\_\_restrict\_\_' qualifier with the independent array arguments. Erroneous results will occur if these options are incorrectly applied!`|
7421+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7422
7423+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7424|:remark:`remark:` |nbsp| :placeholder:`A`:diagtext:`; allow reordering by specifying '#pragma clang loop vectorize(enable)' before the loop or by providing the compiler option '-ffast-math'.`|
7425+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7426
7427
7428-Wpass-failed
7429-------------
7430This diagnostic is enabled by default.
7431
7432**Diagnostic text:**
7433
7434The text of this diagnostic is not controlled by Clang.
7435
7436
7437-Rpass-missed
7438-------------
7439**Diagnostic text:**
7440
7441The text of this diagnostic is not controlled by Clang.
7442
7443
7444-Wpch-date-time
7445---------------
7446This diagnostic is enabled by default.
7447
7448**Diagnostic text:**
7449
7450+---------------------------+--------------------------------+-----------------------------------------------------+
7451|:warning:`warning:` |nbsp| |+------------------------------+| |nbsp| :diagtext:`uses \_\_DATE\_\_ or \_\_TIME\_\_`|
7452| ||:diagtext:`precompiled header`|| |
7453| |+------------------------------+| |
7454| ||:diagtext:`module` || |
7455| |+------------------------------+| |
7456+---------------------------+--------------------------------+-----------------------------------------------------+
7457
7458
7459-Wpedantic
7460----------
Richard Smithce9d5862016-09-14 01:51:10 +00007461Also controls `-Wretained-language-linkage`_, `-Wcomplex-component-init`_, `-Wextended-offsetof`_, `-Wnested-anon-types`_, `-Wdeclaration-after-statement`_, `-Wempty-translation-unit`_, `-Wnullability-extension`_, `-Wdollar-in-identifier-extension`_, `-Wlanguage-extension-token`_, `-Wimport-preprocessor-directive-pedantic`_, `-Wembedded-directive`_, `-Wgnu-anonymous-struct`_, `-Wgnu-auto-type`_, `-Wc++14-binary-literal`_, `-Wgnu-binary-literal`_, `-Wgnu-compound-literal-initializer`_, `-Wgnu-case-range`_, `-Wgnu-complex-integer`_, `-Wgnu-conditional-omitted-operand`_, `-Wgnu-empty-initializer`_, `-Wgnu-empty-struct`_, `-Wc++11-extra-semi`_, `-Wgnu-flexible-array-initializer`_, `-Wgnu-flexible-array-union-member`_, `-Wgnu-folding-constant`_, `-Wflexible-array-extensions`_, `-Wfour-char-constants`_, `-Wgnu-imaginary-constant`_, `-Wgnu-include-next`_, `-Wgnu-label-as-value`_, `-Wc++11-long-long`_, `-Wlong-long`_, `-Woverlength-strings`_, `-Wgnu-redeclared-enum`_, `-Wgnu-statement-expression`_, `-Wgnu-union-cast`_, `-Wkeyword-macro`_, `-Wvariadic-macros`_, `-Wvla-extension`_, `-Wzero-length-array`_, `-Wgnu-zero-line-directive`_, `-Wgnu-zero-variadic-macro-arguments`_, `-Wformat-pedantic`_, `-Wc11-extensions`_, `-Wmicrosoft-charize`_, `-Wmicrosoft-cpp-macro`_, `-Wmicrosoft-fixed-enum`_, `-Wmicrosoft-redeclare-static`_, `-Wmicrosoft-enum-forward-reference`_, `-Wmicrosoft-flexible-array`_, `-Wmicrosoft-comment-paste`_, `-Wmicrosoft-end-of-file`_.
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007462
7463**Diagnostic text:**
7464
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007465+------------------------------------------------------------------------+
7466|:warning:`warning:` |nbsp| :diagtext:`'enable\_if' is a clang extension`|
7467+------------------------------------------------------------------------+
7468
Richard Smithce9d5862016-09-14 01:51:10 +00007469+--------------------------------------------------------------------------------+
7470|:warning:`warning:` |nbsp| :diagtext:`designated initializers are a C99 feature`|
7471+--------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007472
Richard Smithce9d5862016-09-14 01:51:10 +00007473+--------------------------------------------------------------------------------------------+
7474|:warning:`warning:` |nbsp| :diagtext:`ISO C++ does not allow 'main' to be used by a program`|
7475+--------------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007476
Richard Smithce9d5862016-09-14 01:51:10 +00007477+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+
7478|:warning:`warning:` |nbsp| :diagtext:`C++98 requires an accessible copy constructor for class` |nbsp| :placeholder:`C` |nbsp| :diagtext:`when binding a reference to a temporary; was` |nbsp| |+---------------------+|
7479| ||:diagtext:`private` ||
7480| |+---------------------+|
7481| ||:diagtext:`protected`||
7482| |+---------------------+|
7483+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007484
Richard Smithce9d5862016-09-14 01:51:10 +00007485+--------------------------------------------------------+--------------------+------------------------------------------------------------+
7486|:warning:`warning:` |nbsp| :diagtext:`anonymous` |nbsp| |+------------------+| |nbsp| :diagtext:`cannot be '`:placeholder:`B`:diagtext:`'`|
7487| ||:diagtext:`struct`|| |
7488| |+------------------+| |
7489| ||:diagtext:`union` || |
7490| |+------------------+| |
7491+--------------------------------------------------------+--------------------+------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007492
7493+--------------------------------------------------------------------+-----------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------+
7494|:warning:`warning:` |nbsp| :diagtext:`no viable constructor` |nbsp| |+---------------------------------------+| |nbsp| :diagtext:`of type` |nbsp| :placeholder:`B`:diagtext:`; C++98 requires a copy constructor when binding a reference to a temporary`|
7495| ||:diagtext:`copying variable` || |
7496| |+---------------------------------------+| |
7497| ||:diagtext:`copying parameter` || |
7498| |+---------------------------------------+| |
7499| ||:diagtext:`returning object` || |
7500| |+---------------------------------------+| |
7501| ||:diagtext:`throwing object` || |
7502| |+---------------------------------------+| |
7503| ||:diagtext:`copying member subobject` || |
7504| |+---------------------------------------+| |
7505| ||:diagtext:`copying array element` || |
7506| |+---------------------------------------+| |
7507| ||:diagtext:`allocating object` || |
7508| |+---------------------------------------+| |
7509| ||:diagtext:`copying temporary` || |
7510| |+---------------------------------------+| |
7511| ||:diagtext:`initializing base subobject`|| |
7512| |+---------------------------------------+| |
7513| ||:diagtext:`initializing vector element`|| |
7514| |+---------------------------------------+| |
7515| ||:diagtext:`capturing value` || |
7516| |+---------------------------------------+| |
7517+--------------------------------------------------------------------+-----------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------+
7518
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007519+--------------------------------------------------------------------------------------------------------------------------------------+
7520|:warning:`warning:` |nbsp| :diagtext:`parameter` |nbsp| :placeholder:`A` |nbsp| :diagtext:`was not declared, defaulting to type 'int'`|
7521+--------------------------------------------------------------------------------------------------------------------------------------+
7522
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007523+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7524|:warning:`warning:` |nbsp| :diagtext:`qualifier in explicit instantiation of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires a template-id (a typedef is not permitted)`|
7525+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7526
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007527+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
7528|:warning:`warning:` |nbsp| :diagtext:`static` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`is used in an inline function with external linkage`|
7529| ||:diagtext:`function`|| |
7530| |+--------------------+| |
7531| ||:diagtext:`variable`|| |
7532| |+--------------------+| |
7533+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
7534
Richard Smithce9d5862016-09-14 01:51:10 +00007535+---------------------------------------------------------------------------------------+
7536|:warning:`warning:` |nbsp| :diagtext:`ISO C forbids forward references to 'enum' types`|
7537+---------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007538
7539+----------------------------------------------------------------------------------------------------------------------------------------------+-------------------+-------------+
7540|:warning:`warning:` |nbsp| :diagtext:`ISO C restricts enumerator values to range of 'int' (`:placeholder:`A` |nbsp| :diagtext:`is too` |nbsp| |+-----------------+|:diagtext:`)`|
7541| ||:diagtext:`small`|| |
7542| |+-----------------+| |
7543| ||:diagtext:`large`|| |
7544| |+-----------------+| |
7545+----------------------------------------------------------------------------------------------------------------------------------------------+-------------------+-------------+
7546
Richard Smithce9d5862016-09-14 01:51:10 +00007547+--------------------------------------------------------------------------------------------------+
7548|:warning:`warning:` |nbsp| :diagtext:`size of static array must be an integer constant expression`|
7549+--------------------------------------------------------------------------------------------------+
7550
7551+-----------------------------------------------------------------------------------------------+
7552|:warning:`warning:` |nbsp| :diagtext:`initializer for aggregate is not a compile-time constant`|
7553+-----------------------------------------------------------------------------------------------+
7554
7555+-------------------------------------------------------------------------------+
7556|:warning:`warning:` |nbsp| :diagtext:`flexible array members are a C99 feature`|
7557+-------------------------------------------------------------------------------+
7558
7559+---------------------------------------------------------------+-----------------------+--------------------------------+
7560|:warning:`warning:` |nbsp| :diagtext:`invalid application of '`|+---------------------+|:diagtext:`' to a function type`|
7561| ||:diagtext:`sizeof` || |
7562| |+---------------------+| |
7563| ||:diagtext:`alignof` || |
7564| |+---------------------+| |
7565| ||:diagtext:`vec\_step`|| |
7566| |+---------------------+| |
7567+---------------------------------------------------------------+-----------------------+--------------------------------+
7568
7569+---------------------------------------------------------------+-----------------------+----------------------------+
7570|:warning:`warning:` |nbsp| :diagtext:`invalid application of '`|+---------------------+|:diagtext:`' to a void type`|
7571| ||:diagtext:`sizeof` || |
7572| |+---------------------+| |
7573| ||:diagtext:`alignof` || |
7574| |+---------------------+| |
7575| ||:diagtext:`vec\_step`|| |
7576| |+---------------------+| |
7577+---------------------------------------------------------------+-----------------------+----------------------------+
7578
7579+-------------------------------------------------------------------------------------------+
7580|:warning:`warning:` |nbsp| :diagtext:`ISO C90 does not allow subscripting non-lvalue array`|
7581+-------------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007582
7583+----------------------------------------------------------------------------------------+
Richard Smithce9d5862016-09-14 01:51:10 +00007584|:warning:`warning:` |nbsp| :diagtext:`subscript of a pointer to void is a GNU extension`|
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007585+----------------------------------------------------------------------------------------+
7586
Richard Smithce9d5862016-09-14 01:51:10 +00007587+-------------------------------------------------------------------------------------------------------+
7588|:warning:`warning:` |nbsp| :diagtext:`ISO C forbids taking the address of an expression of type 'void'`|
7589+-------------------------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007590
Richard Smithce9d5862016-09-14 01:51:10 +00007591+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7592|:warning:`warning:` |nbsp| :diagtext:`ordered comparison between pointer and zero (`:placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`:diagtext:`) is an extension`|
7593+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007594
7595+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7596|:warning:`warning:` |nbsp| :diagtext:`equality comparison between function pointer and void pointer (`:placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`:diagtext:`)`|
7597+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
7598
Richard Smithce9d5862016-09-14 01:51:10 +00007599+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------------------------------+
7600|:warning:`warning:` |nbsp| :diagtext:`arithmetic on`|+---------------------+| |nbsp| :diagtext:`pointer`|+-------------+| |nbsp| :diagtext:`to void is a GNU extension`|
7601| || |nbsp| :diagtext:`a`|| || || |
7602| |+---------------------+| |+-------------+| |
7603| || || ||:diagtext:`s`|| |
7604| |+---------------------+| |+-------------+| |
7605+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007606
Richard Smithce9d5862016-09-14 01:51:10 +00007607+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------+-------------------------+---------------------------------+---------------+------------------------+---------------------------------------------------+--------------------------------------+
7608|:warning:`warning:` |nbsp| :diagtext:`arithmetic on`|+---------------------+| |nbsp| :diagtext:`pointer`|+-------------+| |nbsp| :diagtext:`to`|+-----------------------+| |nbsp| :diagtext:`function type`|+-------------+| |nbsp| :placeholder:`B`|+-------------------------------------------------+| |nbsp| :diagtext:`is a GNU extension`|
7609| || |nbsp| :diagtext:`a`|| || || || |nbsp| :diagtext:`the`|| || || || || |
7610| |+---------------------+| |+-------------+| |+-----------------------+| |+-------------+| |+-------------------------------------------------+| |
7611| || || ||:diagtext:`s`|| || || ||:diagtext:`s`|| ||+-----------------------------------------------+|| |
7612| |+---------------------+| |+-------------+| |+-----------------------+| |+-------------+| ||| |nbsp| :diagtext:`and` |nbsp| :placeholder:`D`||| |
7613| | | | | | | | | ||+-----------------------------------------------+|| |
7614| | | | | | | | | |+-------------------------------------------------+| |
7615+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------+-------------------------+---------------------------------+---------------+------------------------+---------------------------------------------------+--------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007616
Richard Smithce9d5862016-09-14 01:51:10 +00007617+-----------------------------------------------------------------------------------------------------------------------+
7618|:warning:`warning:` |nbsp| :diagtext:`ISO C does not support '++'/'--' on complex integer type` |nbsp| :placeholder:`A`|
7619+-----------------------------------------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007620
Richard Smithce9d5862016-09-14 01:51:10 +00007621+--------------------------------------------------------------------------------------------------------------------+
7622|:warning:`warning:` |nbsp| :diagtext:`ISO C does not support '~' for complex conjugation of` |nbsp| :placeholder:`A`|
7623+--------------------------------------------------------------------------------------------------------------------+
7624
7625+------------------------------------------------------------------------------------------------------------+
7626|:warning:`warning:` |nbsp| :diagtext:`complex numbers are an extension in a freestanding C99 implementation`|
7627+------------------------------------------------------------------------------------------------------------+
7628
7629+-------------------------------------------------------------------------------------------------------------+
7630|:warning:`warning:` |nbsp| :diagtext:`cast between pointer-to-function and pointer-to-object is an extension`|
7631+-------------------------------------------------------------------------------------------------------------+
7632
7633+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------+
7634|:warning:`warning:` |nbsp| :diagtext:`implicit conversion from array size expression of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| |+-----------------------+| |nbsp| :diagtext:`type` |nbsp| :placeholder:`C` |nbsp| :diagtext:`is a C++11 extension`|
7635| ||:diagtext:`integral` || |
7636| |+-----------------------+| |
7637| ||:diagtext:`enumeration`|| |
7638| |+-----------------------+| |
7639+---------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+----------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007640
7641+---------------------------+----------------------------------------------------------------+----------------------------------------------------------------------+
7642|:warning:`warning:` |nbsp| |+--------------------------------------------------------------+| |nbsp| :diagtext:`converts between void pointer and function pointer`|
7643| ||:diagtext:`assigning to different types` || |
7644| |+--------------------------------------------------------------+| |
7645| ||:diagtext:`passing to parameter of different type` || |
7646| |+--------------------------------------------------------------+| |
7647| ||:diagtext:`returning from function with different return type`|| |
7648| |+--------------------------------------------------------------+| |
7649| ||:diagtext:`converting between types` || |
7650| |+--------------------------------------------------------------+| |
7651| ||:diagtext:`initializing with expression of different type` || |
7652| |+--------------------------------------------------------------+| |
7653| ||:diagtext:`sending to parameter of different type` || |
7654| |+--------------------------------------------------------------+| |
7655| ||:diagtext:`casting between types` || |
7656| |+--------------------------------------------------------------+| |
7657+---------------------------+----------------------------------------------------------------+----------------------------------------------------------------------+
7658
Richard Smithce9d5862016-09-14 01:51:10 +00007659+--------------------------------------------------------------------------------------------------------------------------------------------------------+
7660|:warning:`warning:` |nbsp| :diagtext:`kernel function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a member function; this may not be accepted by nvcc`|
7661+--------------------------------------------------------------------------------------------------------------------------------------------------------+
7662
7663+--------------------------------------------------------------------------------------------------+
7664|:warning:`warning:` |nbsp| :diagtext:`C99 forbids conditional expressions with only one void side`|
7665+--------------------------------------------------------------------------------------------------+
7666
7667+-------------------------------------------------------------------------------------------------------------------------------------+
7668|:warning:`warning:` |nbsp| :diagtext:`C99 forbids casting nonscalar type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to the same type`|
7669+-------------------------------------------------------------------------------------------------------------------------------------+
7670
7671+---------------------------------------------------------------------------------------------------------------------------+
7672|:warning:`warning:` |nbsp| :diagtext:`use of the` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute is a C++14 extension`|
7673+---------------------------------------------------------------------------------------------------------------------------+
7674
7675+---------------------------------------------------------------------------------------------------------------------------+
7676|:warning:`warning:` |nbsp| :diagtext:`use of the` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute is a C++1z extension`|
7677+---------------------------------------------------------------------------------------------------------------------------+
7678
7679+-----------------------------------------------------------------------------+--------------------+---------------------------------------------+
7680|:warning:`warning:` |nbsp| :diagtext:`types declared in an anonymous` |nbsp| |+------------------+| |nbsp| :diagtext:`are a Microsoft extension`|
7681| ||:diagtext:`struct`|| |
7682| |+------------------+| |
7683| ||:diagtext:`union` || |
7684| |+------------------+| |
7685+-----------------------------------------------------------------------------+--------------------+---------------------------------------------+
7686
7687+---------------------------------------------------+----------------------+-----------------------------------------------------------------------------+
7688|:warning:`warning:` |nbsp| :diagtext:`void` |nbsp| |+--------------------+| |nbsp| :placeholder:`A` |nbsp| :diagtext:`should not return void expression`|
7689| ||:diagtext:`function`|| |
7690| |+--------------------+| |
7691| ||:diagtext:`method` || |
7692| |+--------------------+| |
7693| ||:diagtext:`block` || |
7694| |+--------------------+| |
7695+---------------------------------------------------+----------------------+-----------------------------------------------------------------------------+
7696
7697+--------------------------------------------------------------------------------------------------+
7698|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' cannot be signed or unsigned`|
7699+--------------------------------------------------------------------------------------------------+
7700
7701+---------------------------+----------------------------------+------------------------------+-----------------------+----------------------------+
7702|:warning:`warning:` |nbsp| |+--------------------------------+|:diagtext:`array size` |nbsp| |+---------------------+|:diagtext:`is a C99 feature`|
7703| ||:diagtext:`qualifier in` |nbsp| || || || |
7704| |+--------------------------------+| |+---------------------+| |
7705| ||:diagtext:`static` |nbsp| || || || |
7706| |+--------------------------------+| |+---------------------+| |
7707| || || ||:diagtext:`'\[\*\] '`|| |
7708| |+--------------------------------+| |+---------------------+| |
7709+---------------------------+----------------------------------+------------------------------+-----------------------+----------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007710
7711+--------------------------------------------------------+------------------------------------------------+
7712|:warning:`warning:` |nbsp| :diagtext:`extra ';'` |nbsp| |+----------------------------------------------+|
7713| ||:diagtext:`outside of a function` ||
7714| |+----------------------------------------------+|
7715| ||+--------------------------------------------+||
7716| |||:diagtext:`inside a` |nbsp| :placeholder:`B`|||
7717| ||+--------------------------------------------+||
7718| |+----------------------------------------------+|
7719| ||:diagtext:`inside instance variable list` ||
7720| |+----------------------------------------------+|
7721| ||:diagtext:`after member function definition` ||
7722| |+----------------------------------------------+|
7723+--------------------------------------------------------+------------------------------------------------+
7724
Richard Smithce9d5862016-09-14 01:51:10 +00007725+-----------------------------------------------------------------------------------------+
7726|:warning:`warning:` |nbsp| :diagtext:`'\_\_thread' before '`:placeholder:`A`:diagtext:`'`|
7727+-----------------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007728
7729+----------------------------------------------------------------------------------------+
Richard Smithce9d5862016-09-14 01:51:10 +00007730|:warning:`warning:` |nbsp| :diagtext:`type-less parameter names in function declaration`|
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007731+----------------------------------------------------------------------------------------+
7732
Richard Smithce9d5862016-09-14 01:51:10 +00007733+-------------------------------------------------------------------------------------------------+
7734|:warning:`warning:` |nbsp| :diagtext:`variable declaration in for loop is a C99-specific feature`|
7735+-------------------------------------------------------------------------------------------------+
7736
7737+-----------------------------------------------------------------------------------+
7738|:warning:`warning:` |nbsp| :diagtext:`compound literals are a C99-specific feature`|
7739+-----------------------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007740
7741+-------------------------------------------------------------------------------------------------------+
7742|:warning:`warning:` |nbsp| :diagtext:`commas at the end of enumerator lists are a C99-specific feature`|
7743+-------------------------------------------------------------------------------------------------------+
7744
Richard Smithce9d5862016-09-14 01:51:10 +00007745+--------------------------------------------------------------------------------------------------+
7746|:warning:`warning:` |nbsp| :diagtext:`commas at the end of enumerator lists are a C++11 extension`|
7747+--------------------------------------------------------------------------------------------------+
7748
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007749+-----------------------------------------------------------------------------------------------------------+
7750|:warning:`warning:` |nbsp| :diagtext:`enumeration types with a fixed underlying type are a C++11 extension`|
7751+-----------------------------------------------------------------------------------------------------------+
7752
Richard Smithce9d5862016-09-14 01:51:10 +00007753+-----------------------------------------------------------------------+
7754|:warning:`warning:` |nbsp| :diagtext:`use of GNU array range extension`|
7755+-----------------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007756
Richard Smithce9d5862016-09-14 01:51:10 +00007757+------------------------------------------------------------------------------------------------+
7758|:warning:`warning:` |nbsp| :diagtext:`exception specification of '...' is a Microsoft extension`|
7759+------------------------------------------------------------------------------------------------+
7760
7761+-----------------------------------------------------------------------------+
7762|:warning:`warning:` |nbsp| :diagtext:`extern templates are a C++11 extension`|
7763+-----------------------------------------------------------------------------+
7764
7765+------------------------------------------------------------+
7766|:warning:`warning:` |nbsp| :diagtext:`multi-line // comment`|
7767+------------------------------------------------------------+
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007768
7769+-----------------------------------------------------------------------------------+
7770|:warning:`warning:` |nbsp| :diagtext:`// comments are not allowed in this language`|
7771+-----------------------------------------------------------------------------------+
7772
Richard Smithce9d5862016-09-14 01:51:10 +00007773+----------------------------------------------------------------+
7774|:warning:`warning:` |nbsp| :diagtext:`no newline at end of file`|
7775+----------------------------------------------------------------+
7776
7777+------------------------------------------------------------------------------------------------------------+
7778|:warning:`warning:` |nbsp| :diagtext:`use of non-standard escape character '\\`:placeholder:`A`:diagtext:`'`|
7779+------------------------------------------------------------------------------------------------------------+
7780
7781+---------------------------------------------------------------------------------------+
7782|:warning:`warning:` |nbsp| :diagtext:`hexadecimal floating constants are a C99 feature`|
7783+---------------------------------------------------------------------------------------+
7784
7785+----------------------------------------------------------------------------------------+
7786|:warning:`warning:` |nbsp| :diagtext:`hexadecimal floating literals are a C++1z feature`|
7787+----------------------------------------------------------------------------------------+
7788
7789+---------------------------------------------------------------------+
7790|:warning:`warning:` |nbsp| :diagtext:`#ident is a language extension`|
7791+---------------------------------------------------------------------+
7792
7793+-----------------------------------------------------------------------+
7794|:warning:`warning:` |nbsp| :diagtext:`#warning is a language extension`|
7795+-----------------------------------------------------------------------+
7796
7797+-----------------------------------------------------------------------+
7798|:warning:`warning:` |nbsp| :diagtext:`comma operator in operand of #if`|
7799+-----------------------------------------------------------------------+
7800
7801+----------------------------------------------------------------------------------------------------------------+
7802|:warning:`warning:` |nbsp| :diagtext:`\_\_VA\_ARGS\_\_ can only appear in the expansion of a C99 variadic macro`|
7803+----------------------------------------------------------------------------------------------------------------+
7804
7805+------------------------------------------------------------------------------+
7806|:warning:`warning:` |nbsp| :diagtext:`empty macro arguments are a C99 feature`|
7807+------------------------------------------------------------------------------+
7808
7809+----------------------------------------------------------------------------------------------------------------------------------------+
7810|:warning:`warning:` |nbsp| :diagtext:`C requires #line number to be less than` |nbsp| :placeholder:`A`:diagtext:`, allowed as extension`|
7811+----------------------------------------------------------------------------------------------------------------------------------------+
7812
7813+-------------------------------------------------------------------------------------------------+
7814|:warning:`warning:` |nbsp| :diagtext:`macro expansion producing 'defined' has undefined behavior`|
7815+-------------------------------------------------------------------------------------------------+
7816
Richard Smithb6a3b4b2016-09-12 05:58:29 +00007817
7818-Wpedantic-core-features
7819------------------------
7820**Diagnostic text:**
7821
7822+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
7823|:warning:`warning:` |nbsp| :diagtext:`OpenCL extension` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is core feature or supported optional core feature - ignoring`|
7824+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
7825
7826
7827-Wpessimizing-move
7828------------------
7829**Diagnostic text:**
7830
7831+--------------------------------------------------------------------------------------+
7832|:warning:`warning:` |nbsp| :diagtext:`moving a temporary object prevents copy elision`|
7833+--------------------------------------------------------------------------------------+
7834
7835+--------------------------------------------------------------------------------------------------------+
7836|:warning:`warning:` |nbsp| :diagtext:`moving a local object in a return statement prevents copy elision`|
7837+--------------------------------------------------------------------------------------------------------+
7838
7839
7840-Wpointer-arith
7841---------------
7842Some of the diagnostics controlled by this flag are enabled by default.
7843
7844**Diagnostic text:**
7845
7846+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------+-------------------------+---------------------------------+---------------+------------------------+---------------------------------------------------+--------------------------------------+
7847|:warning:`warning:` |nbsp| :diagtext:`arithmetic on`|+---------------------+| |nbsp| :diagtext:`pointer`|+-------------+| |nbsp| :diagtext:`to`|+-----------------------+| |nbsp| :diagtext:`function type`|+-------------+| |nbsp| :placeholder:`B`|+-------------------------------------------------+| |nbsp| :diagtext:`is a GNU extension`|
7848| || |nbsp| :diagtext:`a`|| || || || |nbsp| :diagtext:`the`|| || || || || |
7849| |+---------------------+| |+-------------+| |+-----------------------+| |+-------------+| |+-------------------------------------------------+| |
7850| || || ||:diagtext:`s`|| || || ||:diagtext:`s`|| ||+-----------------------------------------------+|| |
7851| |+---------------------+| |+-------------+| |+-----------------------+| |+-------------+| ||| |nbsp| :diagtext:`and` |nbsp| :placeholder:`D`||| |
7852| | | | | | | | | ||+-----------------------------------------------+|| |
7853| | | | | | | | | |+-------------------------------------------------+| |
7854+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------+-------------------------+---------------------------------+---------------+------------------------+---------------------------------------------------+--------------------------------------+
7855
7856+----------------------------------------------------------------------------------------+
7857|:warning:`warning:` |nbsp| :diagtext:`subscript of a pointer to void is a GNU extension`|
7858+----------------------------------------------------------------------------------------+
7859
7860+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------------------------------+
7861|:warning:`warning:` |nbsp| :diagtext:`arithmetic on`|+---------------------+| |nbsp| :diagtext:`pointer`|+-------------+| |nbsp| :diagtext:`to void is a GNU extension`|
7862| || |nbsp| :diagtext:`a`|| || || |
7863| |+---------------------+| |+-------------+| |
7864| || || ||:diagtext:`s`|| |
7865| |+---------------------+| |+-------------+| |
7866+----------------------------------------------------+-----------------------+---------------------------+---------------+----------------------------------------------+
7867
7868+---------------------------------------------------------------+-----------------------+--------------------------------+
7869|:warning:`warning:` |nbsp| :diagtext:`invalid application of '`|+---------------------+|:diagtext:`' to a function type`|
7870| ||:diagtext:`sizeof` || |
7871| |+---------------------+| |
7872| ||:diagtext:`alignof` || |
7873| |+---------------------+| |
7874| ||:diagtext:`vec\_step`|| |
7875| |+---------------------+| |
7876+---------------------------------------------------------------+-----------------------+--------------------------------+
7877
7878+---------------------------------------------------------------+-----------------------+----------------------------+
7879|:warning:`warning:` |nbsp| :diagtext:`invalid application of '`|+---------------------+|:diagtext:`' to a void type`|
7880| ||:diagtext:`sizeof` || |
7881| |+---------------------+| |
7882| ||:diagtext:`alignof` || |
7883| |+---------------------+| |
7884| ||:diagtext:`vec\_step`|| |
7885| |+---------------------+| |
7886+---------------------------------------------------------------+-----------------------+----------------------------+
7887
7888+-----------------------------------------------------------------------------------------------------------------------------------------------------+
7889|:warning:`warning:` |nbsp| :diagtext:`subtraction of pointers to type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of zero size has undefined behavior`|
7890+-----------------------------------------------------------------------------------------------------------------------------------------------------+
7891
7892
7893-Wpointer-bool-conversion
7894-------------------------
7895This diagnostic is enabled by default.
7896
7897**Diagnostic text:**
7898
7899+------------------------------------------------------+---------------------------+---------------------------------------------------------------------------------------------+
7900|:warning:`warning:` |nbsp| :diagtext:`nonnull` |nbsp| |+-------------------------+| |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' will evaluate to 'true' on first encounter`|
7901| ||:diagtext:`function call`|| |
7902| |+-------------------------+| |
7903| ||:diagtext:`parameter` || |
7904| |+-------------------------+| |
7905+------------------------------------------------------+---------------------------+---------------------------------------------------------------------------------------------+
7906
7907+-------------------------------------------------+------------------------------+---------------------------------------------------------------------------------+
7908|:warning:`warning:` |nbsp| :diagtext:`address of`|+----------------------------+| |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' will always evaluate to 'true'`|
7909| || || |
7910| |+----------------------------+| |
7911| || |nbsp| :diagtext:`function`|| |
7912| |+----------------------------+| |
7913| || |nbsp| :diagtext:`array` || |
7914| |+----------------------------+| |
7915+-------------------------------------------------+------------------------------+---------------------------------------------------------------------------------+
7916
7917
7918-Wpointer-sign
7919--------------
7920This diagnostic is enabled by default.
7921
7922**Diagnostic text:**
7923
7924+---------------------------+----------------------------------------------------------------+----------------------------------------------------------------------------------+
7925|:warning:`warning:` |nbsp| |+--------------------------------------------------------------+| |nbsp| :diagtext:`converts between pointers to integer types with different sign`|
7926| ||:diagtext:`assigning to different types` || |
7927| |+--------------------------------------------------------------+| |
7928| ||:diagtext:`passing to parameter of different type` || |
7929| |+--------------------------------------------------------------+| |
7930| ||:diagtext:`returning from function with different return type`|| |
7931| |+--------------------------------------------------------------+| |
7932| ||:diagtext:`converting between types` || |
7933| |+--------------------------------------------------------------+| |
7934| ||:diagtext:`initializing with expression of different type` || |
7935| |+--------------------------------------------------------------+| |
7936| ||:diagtext:`sending to parameter of different type` || |
7937| |+--------------------------------------------------------------+| |
7938| ||:diagtext:`casting between types` || |
7939| |+--------------------------------------------------------------+| |
7940+---------------------------+----------------------------------------------------------------+----------------------------------------------------------------------------------+
7941
7942
7943-Wpointer-to-int-cast
7944---------------------
7945This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
7946
7947-Wpointer-type-mismatch
7948-----------------------
7949This diagnostic is enabled by default.
7950
7951**Diagnostic text:**
7952
7953+------------------------------------------------------------+
7954|:warning:`warning:` |nbsp| :diagtext:`pointer type mismatch`|
7955+------------------------------------------------------------+
7956
7957
7958-Wpotentially-evaluated-expression
7959----------------------------------
7960This diagnostic is enabled by default.
7961
7962**Diagnostic text:**
7963
7964+----------------------------------------------------------------------------------------------------------------------------------+
7965|:warning:`warning:` |nbsp| :diagtext:`expression with side effects will be evaluated despite being used as an operand to 'typeid'`|
7966+----------------------------------------------------------------------------------------------------------------------------------+
7967
7968
7969-Wpragma-once-outside-header
7970----------------------------
7971This diagnostic is enabled by default.
7972
7973**Diagnostic text:**
7974
7975+----------------------------------------------------------------+
7976|:warning:`warning:` |nbsp| :diagtext:`#pragma once in main file`|
7977+----------------------------------------------------------------+
7978
7979
7980-Wpragma-system-header-outside-header
7981-------------------------------------
7982This diagnostic is enabled by default.
7983
7984**Diagnostic text:**
7985
7986+----------------------------------------------------------------------------------+
7987|:warning:`warning:` |nbsp| :diagtext:`#pragma system\_header ignored in main file`|
7988+----------------------------------------------------------------------------------+
7989
7990
7991-Wpragmas
7992---------
7993Some of the diagnostics controlled by this flag are enabled by default.
7994
7995Also controls `-Wunknown-pragmas`_, `-Wignored-pragmas`_.
7996
7997**Diagnostic text:**
7998
7999+--------------------------------------------------------------------------------------------------------------------------------------+----------------------+------------------------+
8000|:warning:`warning:` |nbsp| :diagtext:`#pragma redefine\_extname is applicable to external C declarations only; not applied to` |nbsp| |+--------------------+| |nbsp| :placeholder:`B`|
8001| ||:diagtext:`function`|| |
8002| |+--------------------+| |
8003| ||:diagtext:`variable`|| |
8004| |+--------------------+| |
8005+--------------------------------------------------------------------------------------------------------------------------------------+----------------------+------------------------+
8006
8007
8008-Wpredefined-identifier-outside-function
8009----------------------------------------
8010This diagnostic is enabled by default.
8011
8012**Diagnostic text:**
8013
8014+------------------------------------------------------------------------------------------+
8015|:warning:`warning:` |nbsp| :diagtext:`predefined identifier is only valid inside function`|
8016+------------------------------------------------------------------------------------------+
8017
8018
8019-Wprivate-extern
8020----------------
8021This diagnostic is enabled by default.
8022
8023**Diagnostic text:**
8024
8025+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8026|:warning:`warning:` |nbsp| :diagtext:`use of \_\_private\_extern\_\_ on a declaration may not produce external symbol private to the linkage unit and is deprecated`|
8027+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8028
8029
8030-Wprivate-header
8031----------------
8032This diagnostic is an error by default, but the flag ``-Wno-private-header`` can be used to disable the error.
8033
8034**Diagnostic text:**
8035
8036+----------------------------------------------------------------------------------------------------------------+
8037|:error:`error:` |nbsp| :diagtext:`use of private header from outside its module: '`:placeholder:`A`:diagtext:`'`|
8038+----------------------------------------------------------------------------------------------------------------+
8039
8040
8041-Wprofile-instr-out-of-date
8042---------------------------
8043This diagnostic is enabled by default.
8044
8045**Diagnostic text:**
8046
8047+------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------+-------------------+---------------------------------------------------------------+-------------------+--------------------------------------------------------+
8048|:warning:`warning:` |nbsp| :diagtext:`profile data may be out of date: of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`function`|+-------------+|:diagtext:`,` |nbsp| :placeholder:`B` |nbsp| |+-----------------+| |nbsp| :diagtext:`no data and` |nbsp| :placeholder:`C` |nbsp| |+-----------------+| |nbsp| :diagtext:`mismatched data that will be ignored`|
8049| || || ||:diagtext:`:has` || ||:diagtext:`:has` || |
8050| |+-------------+| |+-----------------+| |+-----------------+| |
8051| ||:diagtext:`s`|| ||:diagtext:`:have`|| ||:diagtext:`:have`|| |
8052| |+-------------+| |+-----------------+| |+-----------------+| |
8053+------------------------------------------------------------------------------------------------------------------------------+---------------+---------------------------------------------+-------------------+---------------------------------------------------------------+-------------------+--------------------------------------------------------+
8054
8055
8056-Wprofile-instr-unprofiled
8057--------------------------
8058This diagnostic is enabled by default.
8059
8060**Diagnostic text:**
8061
8062+--------------------------------------------------------------------------------------------------------+
8063|:warning:`warning:` |nbsp| :diagtext:`no profile data available for file "`:placeholder:`A`:diagtext:`"`|
8064+--------------------------------------------------------------------------------------------------------+
8065
8066
8067-Wproperty-access-dot-syntax
8068----------------------------
8069This diagnostic is enabled by default.
8070
8071**Diagnostic text:**
8072
8073+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8074|:warning:`warning:` |nbsp| :diagtext:`property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`not found on object of type` |nbsp| :placeholder:`B`:diagtext:`; did you mean to access property` |nbsp| :placeholder:`C`:diagtext:`?`|
8075+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8076
8077
8078-Wproperty-attribute-mismatch
8079-----------------------------
8080This diagnostic is enabled by default.
8081
8082**Diagnostic text:**
8083
8084+-------------------------------------------------------------------------------------------------------------+
8085|:warning:`warning:` |nbsp| :diagtext:`property attribute in class extension does not match the primary class`|
8086+-------------------------------------------------------------------------------------------------------------+
8087
8088+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8089|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' attribute on property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`does not match the property inherited from` |nbsp| :placeholder:`C`|
8090+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8091
8092+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8093|:warning:`warning:` |nbsp| :diagtext:`getter name mismatch between property redeclaration (`:placeholder:`B`:diagtext:`) and its original declaration (`:placeholder:`A`:diagtext:`)`|
8094+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8095
8096+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8097|:warning:`warning:` |nbsp| :diagtext:`attribute 'readonly' of property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`restricts attribute 'readwrite' of property inherited from` |nbsp| :placeholder:`B`|
8098+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8099
8100
8101-Wprotocol
8102----------
8103This diagnostic is enabled by default.
8104
8105**Diagnostic text:**
8106
8107+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
8108|:warning:`warning:` |nbsp| :diagtext:`method` |nbsp| :placeholder:`A` |nbsp| :diagtext:`in protocol` |nbsp| :placeholder:`B` |nbsp| :diagtext:`not implemented`|
8109+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
8110
8111
8112-Wprotocol-property-synthesis-ambiguity
8113---------------------------------------
8114This diagnostic is enabled by default.
8115
8116**Diagnostic text:**
8117
8118+-----------------------------------------------------------------------------------------------------------------------------+
8119|:warning:`warning:` |nbsp| :diagtext:`property of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`was selected for synthesis`|
8120+-----------------------------------------------------------------------------------------------------------------------------+
8121
8122
8123-Wqualified-void-return-type
8124----------------------------
8125This diagnostic is enabled by default.
8126
8127**Diagnostic text:**
8128
8129+---------------------------------------------------------------------------------------------------------+
8130|:warning:`warning:` |nbsp| :diagtext:`function cannot return qualified void type` |nbsp| :placeholder:`A`|
8131+---------------------------------------------------------------------------------------------------------+
8132
8133
8134-Wrange-loop-analysis
8135---------------------
8136**Diagnostic text:**
8137
8138+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8139|:warning:`warning:` |nbsp| :diagtext:`loop variable` |nbsp| :placeholder:`A` |nbsp| |nbsp| :diagtext:`is initialized with a value of a different type` |nbsp| :diagtext:`resulting in a copy`|
8140+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8141
8142+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8143|:warning:`warning:` |nbsp| :diagtext:`loop variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`creates a copy from type` |nbsp| :placeholder:`C`|
8144+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8145
8146+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8147|:warning:`warning:` |nbsp| :diagtext:`loop variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is always a copy because the range of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`does not return a reference`|
8148+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8149
8150
8151-Wreadonly-iboutlet-property
8152----------------------------
8153This diagnostic is enabled by default.
8154
8155**Diagnostic text:**
8156
8157+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8158|:warning:`warning:` |nbsp| :diagtext:`readonly IBOutlet property` |nbsp| :placeholder:`A` |nbsp| :diagtext:`when auto-synthesized may not work correctly with 'nib' loader`|
8159+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8160
8161
8162-Wreceiver-expr
8163---------------
8164This diagnostic is enabled by default.
8165
8166**Diagnostic text:**
8167
8168+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
8169|:warning:`warning:` |nbsp| :diagtext:`receiver type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not 'id' or interface pointer, consider casting it to 'id'`|
8170+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
8171
8172
8173-Wreceiver-forward-class
8174------------------------
8175Some of the diagnostics controlled by this flag are enabled by default.
8176
8177**Diagnostic text:**
8178
8179+--------------------------------------------------------------------------------------------------------------------------------------------------------+
8180|:warning:`warning:` |nbsp| :diagtext:`receiver` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a forward class and corresponding @interface may not exist`|
8181+--------------------------------------------------------------------------------------------------------------------------------------------------------+
8182
8183+---------------------------------------------------------------------------------------------------------------------------------------------+
8184|:warning:`warning:` |nbsp| :diagtext:`receiver type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`for instance message is a forward declaration`|
8185+---------------------------------------------------------------------------------------------------------------------------------------------+
8186
8187
8188-Wredeclared-class-member
8189-------------------------
8190This diagnostic is enabled by default.
8191
8192**Diagnostic text:**
8193
8194+------------------------------------------------------------------------+
8195|:warning:`warning:` |nbsp| :diagtext:`class member cannot be redeclared`|
8196+------------------------------------------------------------------------+
8197
8198
8199-Wredundant-decls
8200-----------------
8201This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8202
8203-Wredundant-move
8204----------------
8205**Diagnostic text:**
8206
8207+-------------------------------------------------------------------------+
8208|:warning:`warning:` |nbsp| :diagtext:`redundant move in return statement`|
8209+-------------------------------------------------------------------------+
8210
8211
8212-Wregister
8213----------
8214This diagnostic is enabled by default.
8215
8216Also controls `-Wdeprecated-register`_.
8217
8218**Diagnostic text:**
8219
8220+----------------------------------------------------------------------------------------------+
8221|:error:`error:` |nbsp| :diagtext:`ISO C++1z does not allow 'register' storage class specifier`|
8222+----------------------------------------------------------------------------------------------+
8223
8224
8225-Wreinterpret-base-class
8226------------------------
8227This diagnostic is enabled by default.
8228
8229**Diagnostic text:**
8230
8231+------------------------------------------------------------------+------------------+---------------------------------------------------------+------------------+-------------------------------+-------------------------------------+-----------------------------------------------------------------------------------+
8232|:warning:`warning:` |nbsp| :diagtext:`'reinterpret\_cast'` |nbsp| |+----------------+| |nbsp| :diagtext:`class` |nbsp| :placeholder:`A` |nbsp| |+----------------+| |nbsp| :diagtext:`its` |nbsp| |+-----------------------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`behaves differently from 'static\_cast'`|
8233| ||:diagtext:`from`|| ||:diagtext:`to` || ||:diagtext:`virtual base` || |
8234| |+----------------+| |+----------------+| |+-----------------------------------+| |
8235| ||:diagtext:`to` || ||:diagtext:`from`|| ||:diagtext:`base at non-zero offset`|| |
8236| |+----------------+| |+----------------+| |+-----------------------------------+| |
8237+------------------------------------------------------------------+------------------+---------------------------------------------------------+------------------+-------------------------------+-------------------------------------+-----------------------------------------------------------------------------------+
8238
8239
8240-Rremark-backend-plugin
8241-----------------------
8242**Diagnostic text:**
8243
8244The text of this diagnostic is not controlled by Clang.
8245
8246
8247-Wreorder
8248---------
8249**Diagnostic text:**
8250
8251+---------------------------+------------------------+-----------------------------------------------------------------------------+-------------------+------------------------+
8252|:warning:`warning:` |nbsp| |+----------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`will be initialized after` |nbsp| |+-----------------+| |nbsp| :placeholder:`D`|
8253| ||:diagtext:`field` || ||:diagtext:`field`|| |
8254| |+----------------------+| |+-----------------+| |
8255| ||:diagtext:`base class`|| ||:diagtext:`base` || |
8256| |+----------------------+| |+-----------------+| |
8257+---------------------------+------------------------+-----------------------------------------------------------------------------+-------------------+------------------------+
8258
8259
8260-Wrequires-super-attribute
8261--------------------------
8262This diagnostic is enabled by default.
8263
8264**Diagnostic text:**
8265
8266+-----------------------------------------------------------------------------------------------------+----------------------------------+
8267|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute cannot be applied to` |nbsp| |+--------------------------------+|
8268| ||:diagtext:`methods in protocols`||
8269| |+--------------------------------+|
8270| ||:diagtext:`dealloc` ||
8271| |+--------------------------------+|
8272+-----------------------------------------------------------------------------------------------------+----------------------------------+
8273
8274
8275-Wreserved-id-macro
8276-------------------
8277**Diagnostic text:**
8278
8279+--------------------------------------------------------------------------+
8280|:warning:`warning:` |nbsp| :diagtext:`macro name is a reserved identifier`|
8281+--------------------------------------------------------------------------+
8282
8283
8284-Wreserved-user-defined-literal
8285-------------------------------
8286Some of the diagnostics controlled by this flag are enabled by default.
8287
8288Also controls `-Wc++11-compat-reserved-user-defined-literal`_.
8289
8290**Diagnostic text:**
8291
8292+-----------------------------------------------------------------------------------------------------------------------+
8293|:warning:`warning:` |nbsp| :diagtext:`invalid suffix on literal; C++11 requires a space between literal and identifier`|
8294+-----------------------------------------------------------------------------------------------------------------------+
8295
8296+-------------------------------------------------------------------------------------------------------------------+
8297|:error:`error:` |nbsp| :diagtext:`invalid suffix on literal; C++11 requires a space between literal and identifier`|
8298+-------------------------------------------------------------------------------------------------------------------+
8299
8300
8301-Wretained-language-linkage
8302---------------------------
8303**Diagnostic text:**
8304
8305+-----------------------------------------------------------------------------------------------------------------------------------------------------+
8306|:warning:`warning:` |nbsp| :diagtext:`friend function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`retaining previous language linkage is an extension`|
8307+-----------------------------------------------------------------------------------------------------------------------------------------------------+
8308
8309
8310-Wreturn-stack-address
8311----------------------
8312This diagnostic is enabled by default.
8313
8314**Diagnostic text:**
8315
8316+---------------------------------------------------------------------------------+
8317|:warning:`warning:` |nbsp| :diagtext:`returning address of label, which is local`|
8318+---------------------------------------------------------------------------------+
8319
8320+--------------------------------------------------------+--------------------------+------------------------------------------+
8321|:warning:`warning:` |nbsp| :diagtext:`returning` |nbsp| |+------------------------+| |nbsp| :diagtext:`local temporary object`|
8322| ||:diagtext:`address of` || |
8323| |+------------------------+| |
8324| ||:diagtext:`reference to`|| |
8325| |+------------------------+| |
8326+--------------------------------------------------------+--------------------------+------------------------------------------+
8327
8328+---------------------------+--------------------------+-------------------------------------------------------------------------------------------------------------------+
8329|:warning:`warning:` |nbsp| |+------------------------+| |nbsp| :diagtext:`stack memory associated with local variable` |nbsp| :placeholder:`B` |nbsp| :diagtext:`returned`|
8330| ||:diagtext:`address of` || |
8331| |+------------------------+| |
8332| ||:diagtext:`reference to`|| |
8333| |+------------------------+| |
8334+---------------------------+--------------------------+-------------------------------------------------------------------------------------------------------------------+
8335
8336
8337-Wreturn-type
8338-------------
8339This diagnostic is enabled by default.
8340
8341Also controls `-Wreturn-type-c-linkage`_.
8342
8343**Diagnostic text:**
8344
8345+-----------------------+---------------------------+---------------------------------------------------------------------+
8346|:error:`error:` |nbsp| |+-------------------------+| |nbsp| :placeholder:`A` |nbsp| :diagtext:`should not return a value`|
8347| ||:diagtext:`void function`|| |
8348| |+-------------------------+| |
8349| ||:diagtext:`void method` || |
8350| |+-------------------------+| |
8351| ||:diagtext:`constructor` || |
8352| |+-------------------------+| |
8353| ||:diagtext:`destructor` || |
8354| |+-------------------------+| |
8355+-----------------------+---------------------------+---------------------------------------------------------------------+
8356
8357+---------------------------------------------------+----------------------+-----------------------------------------------------------------+
8358|:error:`error:` |nbsp| :diagtext:`non-void` |nbsp| |+--------------------+| |nbsp| :placeholder:`A` |nbsp| :diagtext:`should return a value`|
8359| ||:diagtext:`function`|| |
8360| |+--------------------+| |
8361| ||:diagtext:`method` || |
8362| |+--------------------+| |
8363+---------------------------------------------------+----------------------+-----------------------------------------------------------------+
8364
8365+-------------------------------------------------------------------------------+
8366|:warning:`warning:` |nbsp| :diagtext:`control reaches end of non-void function`|
8367+-------------------------------------------------------------------------------+
8368
8369+-----------------------------------------------------------------------------+
8370|:warning:`warning:` |nbsp| :diagtext:`control reaches end of non-void lambda`|
8371+-----------------------------------------------------------------------------+
8372
8373+---------------------------------------------------------------------------------+
8374|:warning:`warning:` |nbsp| :diagtext:`control may reach end of non-void function`|
8375+---------------------------------------------------------------------------------+
8376
8377+-------------------------------------------------------------------------------+
8378|:warning:`warning:` |nbsp| :diagtext:`control may reach end of non-void lambda`|
8379+-------------------------------------------------------------------------------+
8380
8381+---------------------------------------------------+----------------------+-----------------------------------------------------------------+
8382|:error:`error:` |nbsp| :diagtext:`non-void` |nbsp| |+--------------------+| |nbsp| :placeholder:`A` |nbsp| :diagtext:`should return a value`|
8383| ||:diagtext:`function`|| |
8384| |+--------------------+| |
8385| ||:diagtext:`method` || |
8386| |+--------------------+| |
8387+---------------------------------------------------+----------------------+-----------------------------------------------------------------+
8388
8389
8390-Wreturn-type-c-linkage
8391-----------------------
8392This diagnostic is enabled by default.
8393
8394**Diagnostic text:**
8395
8396+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8397|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has C-linkage specified, but returns user-defined type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`which is incompatible with C`|
8398+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8399
8400+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8401|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has C-linkage specified, but returns incomplete type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`which could be incompatible with C`|
8402+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8403
8404
8405-Wrtti-for-exceptions
8406---------------------
8407This diagnostic is enabled by default.
8408
8409**Diagnostic text:**
8410
8411+--------------------------------------------------------------------------------------+
8412|:warning:`warning:` |nbsp| :diagtext:`implicitly enabling rtti for exception handling`|
8413+--------------------------------------------------------------------------------------+
8414
8415
8416-Rsanitize-address
8417------------------
8418**Diagnostic text:**
8419
8420+--------------------------------------------------------------------------------------------------------+
8421|:remark:`remark:` |nbsp| :diagtext:`-fsanitize-address-field-padding applied to` |nbsp| :placeholder:`A`|
8422+--------------------------------------------------------------------------------------------------------+
8423
8424+-----------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------+
8425|:remark:`remark:` |nbsp| :diagtext:`-fsanitize-address-field-padding ignored for` |nbsp| :placeholder:`A` |nbsp| :diagtext:`because it` |nbsp| |+------------------------------------+|
8426| ||:diagtext:`is not C++` ||
8427| |+------------------------------------+|
8428| ||:diagtext:`is packed` ||
8429| |+------------------------------------+|
8430| ||:diagtext:`is a union` ||
8431| |+------------------------------------+|
8432| ||:diagtext:`is trivially copyable` ||
8433| |+------------------------------------+|
8434| ||:diagtext:`has trivial destructor` ||
8435| |+------------------------------------+|
8436| ||:diagtext:`is standard layout` ||
8437| |+------------------------------------+|
8438| ||:diagtext:`is in a blacklisted file`||
8439| |+------------------------------------+|
8440| ||:diagtext:`is blacklisted` ||
8441| |+------------------------------------+|
8442+-----------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------+
8443
8444
8445-Wsection
8446---------
8447This diagnostic is enabled by default.
8448
8449**Diagnostic text:**
8450
8451+----------------------------------------------------------------------------------+
8452|:warning:`warning:` |nbsp| :diagtext:`section does not match previous declaration`|
8453+----------------------------------------------------------------------------------+
8454
8455
8456-Wselector
8457----------
8458Also controls `-Wselector-type-mismatch`_.
8459
8460**Diagnostic text:**
8461
8462+-------------------------------------------------------------------------------------------------------------------------------------------------+
8463|:warning:`warning:` |nbsp| :diagtext:`no method with selector` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is implemented in this translation unit`|
8464+-------------------------------------------------------------------------------------------------------------------------------------------------+
8465
8466
8467-Wselector-type-mismatch
8468------------------------
8469**Diagnostic text:**
8470
8471+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8472|:warning:`warning:` |nbsp| :diagtext:`several methods with selector` |nbsp| :placeholder:`A` |nbsp| :diagtext:`of mismatched types are found for the @selector expression`|
8473+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8474
8475
8476-Wself-assign
8477-------------
8478Some of the diagnostics controlled by this flag are enabled by default.
8479
8480Also controls `-Wself-assign-field`_.
8481
8482**Diagnostic text:**
8483
8484+------------------------------------------------------------------------------------------------------------------------------------------+
8485|:warning:`warning:` |nbsp| :diagtext:`explicitly assigning value of variable of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to itself`|
8486+------------------------------------------------------------------------------------------------------------------------------------------+
8487
8488
8489-Wself-assign-field
8490-------------------
8491This diagnostic is enabled by default.
8492
8493**Diagnostic text:**
8494
8495+--------------------------------------------------------+-------------------------------+-----------------------------+
8496|:warning:`warning:` |nbsp| :diagtext:`assigning` |nbsp| |+-----------------------------+| |nbsp| :diagtext:`to itself`|
8497| ||:diagtext:`field` || |
8498| |+-----------------------------+| |
8499| ||:diagtext:`instance variable`|| |
8500| |+-----------------------------+| |
8501+--------------------------------------------------------+-------------------------------+-----------------------------+
8502
8503
8504-Wself-move
8505-----------
8506**Diagnostic text:**
8507
8508+------------------------------------------------------------------------------------------------------------------------------+
8509|:warning:`warning:` |nbsp| :diagtext:`explicitly moving variable of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to itself`|
8510+------------------------------------------------------------------------------------------------------------------------------+
8511
8512
8513-Wsemicolon-before-method-body
8514------------------------------
8515**Diagnostic text:**
8516
8517+------------------------------------------------------------------------------+
8518|:warning:`warning:` |nbsp| :diagtext:`semicolon before method body is ignored`|
8519+------------------------------------------------------------------------------+
8520
8521
8522-Wsentinel
8523----------
8524This diagnostic is enabled by default.
8525
8526**Diagnostic text:**
8527
8528+------------------------------------------------------------------+-----------------------------+
8529|:warning:`warning:` |nbsp| :diagtext:`missing sentinel in` |nbsp| |+---------------------------+|
8530| ||:diagtext:`function call` ||
8531| |+---------------------------+|
8532| ||:diagtext:`method dispatch`||
8533| |+---------------------------+|
8534| ||:diagtext:`block call` ||
8535| |+---------------------------+|
8536+------------------------------------------------------------------+-----------------------------+
8537
8538+------------------------------------------------------------------------------------------------------------------------------------------------+
8539|:warning:`warning:` |nbsp| :diagtext:`not enough variable arguments in` |nbsp| :placeholder:`A` |nbsp| :diagtext:`declaration to fit a sentinel`|
8540+------------------------------------------------------------------------------------------------------------------------------------------------+
8541
8542
8543-Wsequence-point
8544----------------
8545Synonym for `-Wunsequenced`_.
8546
8547
8548-Wserialized-diagnostics
8549------------------------
8550This diagnostic is enabled by default.
8551
8552**Diagnostic text:**
8553
8554+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8555|:warning:`warning:` |nbsp| :diagtext:`unable to open file` |nbsp| :placeholder:`A` |nbsp| :diagtext:`for serializing diagnostics (`:placeholder:`B`:diagtext:`)`|
8556+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8557
8558+--------------------------------------------------------------------------------------------+
8559|:warning:`warning:` |nbsp| :diagtext:`unable to merge a subprocess's serialized diagnostics`|
8560+--------------------------------------------------------------------------------------------+
8561
8562
8563-Wshadow
8564--------
Richard Smithce9d5862016-09-14 01:51:10 +00008565Some of the diagnostics controlled by this flag are enabled by default.
8566
8567Also controls `-Wshadow-field-in-constructor-modified`_, `-Wshadow-ivar`_.
Richard Smithb6a3b4b2016-09-12 05:58:29 +00008568
8569**Diagnostic text:**
8570
8571+--------------------------------------------------------------------+-------------------------------------------------------------+
8572|:warning:`warning:` |nbsp| :diagtext:`declaration shadows a` |nbsp| |+-----------------------------------------------------------+|
8573| ||:diagtext:`local variable` ||
8574| |+-----------------------------------------------------------+|
8575| ||+-----------------------------------------------+ ||
8576| |||:diagtext:`variable in` |nbsp| :placeholder:`C`| ||
8577| ||+-----------------------------------------------+ ||
8578| |+-----------------------------------------------------------+|
8579| ||+---------------------------------------------------------+||
8580| |||:diagtext:`static data member of` |nbsp| :placeholder:`C`|||
8581| ||+---------------------------------------------------------+||
8582| |+-----------------------------------------------------------+|
8583| ||+--------------------------------------------+ ||
8584| |||:diagtext:`field of` |nbsp| :placeholder:`C`| ||
8585| ||+--------------------------------------------+ ||
8586| |+-----------------------------------------------------------+|
8587+--------------------------------------------------------------------+-------------------------------------------------------------+
8588
8589
8590-Wshadow-all
8591------------
Richard Smithce9d5862016-09-14 01:51:10 +00008592Some of the diagnostics controlled by this flag are enabled by default.
8593
Richard Smithb6a3b4b2016-09-12 05:58:29 +00008594Controls `-Wshadow`_, `-Wshadow-field-in-constructor`_.
8595
8596
8597-Wshadow-field-in-constructor
8598-----------------------------
8599Also controls `-Wshadow-field-in-constructor-modified`_.
8600
8601**Diagnostic text:**
8602
8603+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8604|:warning:`warning:` |nbsp| :diagtext:`constructor parameter` |nbsp| :placeholder:`A` |nbsp| :diagtext:`shadows the field` |nbsp| :placeholder:`B` |nbsp| :diagtext:`of` |nbsp| :placeholder:`C`|
8605+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8606
8607
8608-Wshadow-field-in-constructor-modified
8609--------------------------------------
8610**Diagnostic text:**
8611
8612+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8613|:warning:`warning:` |nbsp| :diagtext:`modifying constructor parameter` |nbsp| :placeholder:`A` |nbsp| :diagtext:`that shadows a field of` |nbsp| :placeholder:`B`|
8614+-----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8615
8616
8617-Wshadow-ivar
8618-------------
8619This diagnostic is enabled by default.
8620
8621**Diagnostic text:**
8622
8623+------------------------------------------------------------------------------------------------------------------------------+
8624|:warning:`warning:` |nbsp| :diagtext:`local declaration of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`hides instance variable`|
8625+------------------------------------------------------------------------------------------------------------------------------+
8626
8627
8628-Wshift-count-negative
8629----------------------
8630This diagnostic is enabled by default.
8631
8632**Diagnostic text:**
8633
8634+--------------------------------------------------------------+
8635|:warning:`warning:` |nbsp| :diagtext:`shift count is negative`|
8636+--------------------------------------------------------------+
8637
8638
8639-Wshift-count-overflow
8640----------------------
8641This diagnostic is enabled by default.
8642
8643**Diagnostic text:**
8644
8645+-------------------------------------------------------------------+
8646|:warning:`warning:` |nbsp| :diagtext:`shift count >= width of type`|
8647+-------------------------------------------------------------------+
8648
8649
8650-Wshift-negative-value
8651----------------------
8652This diagnostic is enabled by default.
8653
8654**Diagnostic text:**
8655
8656+------------------------------------------------------------------------------------+
8657|:warning:`warning:` |nbsp| :diagtext:`shifting a negative signed value is undefined`|
8658+------------------------------------------------------------------------------------+
8659
8660
8661-Wshift-op-parentheses
8662----------------------
8663This diagnostic is enabled by default.
8664
8665**Diagnostic text:**
8666
8667+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8668|:warning:`warning:` |nbsp| :diagtext:`operator '`:placeholder:`A`:diagtext:`' has lower precedence than '`:placeholder:`B`:diagtext:`'; '`:placeholder:`B`:diagtext:`' will be evaluated first`|
8669+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8670
8671
8672-Wshift-overflow
8673----------------
8674This diagnostic is enabled by default.
8675
8676**Diagnostic text:**
8677
8678+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8679|:warning:`warning:` |nbsp| :diagtext:`signed shift result (`:placeholder:`A`:diagtext:`) requires` |nbsp| :placeholder:`B` |nbsp| :diagtext:`bits to represent, but` |nbsp| :placeholder:`C` |nbsp| :diagtext:`only has` |nbsp| :placeholder:`D` |nbsp| :diagtext:`bits`|
8680+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8681
8682
8683-Wshift-sign-overflow
8684---------------------
8685**Diagnostic text:**
8686
8687+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8688|:warning:`warning:` |nbsp| :diagtext:`signed shift result (`:placeholder:`A`:diagtext:`) sets the sign bit of the shift expression's type (`:placeholder:`B`:diagtext:`) and becomes negative`|
8689+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8690
8691
8692-Wshorten-64-to-32
8693------------------
8694**Diagnostic text:**
8695
8696+---------------------------------------------------------------------------------------------------------------------------------------------------------+
8697|:warning:`warning:` |nbsp| :diagtext:`implicit conversion loses integer precision:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
8698+---------------------------------------------------------------------------------------------------------------------------------------------------------+
8699
8700
8701-Wsign-compare
8702--------------
8703**Diagnostic text:**
8704
8705+--------------------------------------------------------------------------------------------------------------------------------------------------------+
8706|:warning:`warning:` |nbsp| :diagtext:`comparison of integers of different signs:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`and` |nbsp| :placeholder:`B`|
8707+--------------------------------------------------------------------------------------------------------------------------------------------------------+
8708
8709
8710-Wsign-conversion
8711-----------------
8712**Diagnostic text:**
8713
8714+----------------------------------------------------------------------------------------------------------------------------------------------------+
8715|:warning:`warning:` |nbsp| :diagtext:`implicit conversion changes signedness:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
8716+----------------------------------------------------------------------------------------------------------------------------------------------------+
8717
8718+---------------------------------------------------------------------------------------------------------------------------------------------+
8719|:warning:`warning:` |nbsp| :diagtext:`operand of ? changes signedness:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
8720+---------------------------------------------------------------------------------------------------------------------------------------------+
8721
8722
8723-Wsign-promo
8724------------
8725This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8726
8727-Wsizeof-array-argument
8728-----------------------
8729This diagnostic is enabled by default.
8730
8731**Diagnostic text:**
8732
8733+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8734|:warning:`warning:` |nbsp| :diagtext:`sizeof on array function parameter will return size of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`instead of` |nbsp| :placeholder:`B`|
8735+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8736
8737
8738-Wsizeof-array-decay
8739--------------------
8740This diagnostic is enabled by default.
8741
8742**Diagnostic text:**
8743
8744+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8745|:warning:`warning:` |nbsp| :diagtext:`sizeof on pointer operation will return size of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`instead of` |nbsp| :placeholder:`B`|
8746+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8747
8748
8749-Wsizeof-pointer-memaccess
8750--------------------------
8751This diagnostic is enabled by default.
8752
8753**Diagnostic text:**
8754
8755+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8756|:warning:`warning:` |nbsp| :diagtext:`'`:placeholder:`A`:diagtext:`' call operates on objects of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`while the size is based on a different type` |nbsp| :placeholder:`C`|
8757+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
8758
8759+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+---------------------------------------------------------------------------------------+
8760|:warning:`warning:` |nbsp| :diagtext:`argument to 'sizeof' in` |nbsp| :placeholder:`A` |nbsp| :diagtext:`call is the same pointer type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`as the` |nbsp| |+-----------------------+|:diagtext:`; expected` |nbsp| :placeholder:`D` |nbsp| :diagtext:`or an explicit length`|
8761| ||:diagtext:`destination`|| |
8762| |+-----------------------+| |
8763| ||:diagtext:`source` || |
8764| |+-----------------------+| |
8765+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------+---------------------------------------------------------------------------------------+
8766
8767
8768-Wsometimes-uninitialized
8769-------------------------
8770**Diagnostic text:**
8771
8772+-----------------------------------------------------------------------------------------------------+----------------------+--------------------------------------------------+--------------------------------------------------------------------------------------------------------------+
8773|:warning:`warning:` |nbsp| :diagtext:`variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is` |nbsp| |+--------------------+| |nbsp| :diagtext:`uninitialized whenever` |nbsp| |+------------------------------------------------------------------------------------------------------------+|
8774| ||:diagtext:`used` || ||+---------------------------------------------------------------+-------------------+ ||
8775| |+--------------------+| |||:diagtext:`'`:placeholder:`D`:diagtext:`' condition is` |nbsp| |+-----------------+| ||
8776| ||:diagtext:`captured`|| ||| ||:diagtext:`true` || ||
8777| |+--------------------+| ||| |+-----------------+| ||
8778| | | ||| ||:diagtext:`false`|| ||
8779| | | ||| |+-----------------+| ||
8780| | | ||+---------------------------------------------------------------+-------------------+ ||
8781| | | |+------------------------------------------------------------------------------------------------------------+|
8782| | | ||+-------------------------------------------------------+--------------------------------------------------+||
8783| | | |||:diagtext:`'`:placeholder:`D`:diagtext:`' loop` |nbsp| |+------------------------------------------------+|||
8784| | | ||| ||:diagtext:`is entered` ||||
8785| | | ||| |+------------------------------------------------+|||
8786| | | ||| ||:diagtext:`exits because its condition is false`||||
8787| | | ||| |+------------------------------------------------+|||
8788| | | ||+-------------------------------------------------------+--------------------------------------------------+||
8789| | | |+------------------------------------------------------------------------------------------------------------+|
8790| | | ||+-------------------------------------------------------+--------------------------------------------------+||
8791| | | |||:diagtext:`'`:placeholder:`D`:diagtext:`' loop` |nbsp| |+------------------------------------------------+|||
8792| | | ||| ||:diagtext:`condition is true` ||||
8793| | | ||| |+------------------------------------------------+|||
8794| | | ||| ||:diagtext:`exits because its condition is false`||||
8795| | | ||| |+------------------------------------------------+|||
8796| | | ||+-------------------------------------------------------+--------------------------------------------------+||
8797| | | |+------------------------------------------------------------------------------------------------------------+|
8798| | | ||+----------------------------------------------------------------------+ ||
8799| | | |||:diagtext:`switch` |nbsp| :placeholder:`D` |nbsp| :diagtext:`is taken`| ||
8800| | | ||+----------------------------------------------------------------------+ ||
8801| | | |+------------------------------------------------------------------------------------------------------------+|
8802| | | ||:diagtext:`its declaration is reached` ||
8803| | | |+------------------------------------------------------------------------------------------------------------+|
8804| | | ||+---------------------------------------------+ ||
8805| | | |||:placeholder:`D` |nbsp| :diagtext:`is called`| ||
8806| | | ||+---------------------------------------------+ ||
8807| | | |+------------------------------------------------------------------------------------------------------------+|
8808+-----------------------------------------------------------------------------------------------------+----------------------+--------------------------------------------------+--------------------------------------------------------------------------------------------------------------+
8809
8810
8811-Wsource-uses-openmp
8812--------------------
8813Some of the diagnostics controlled by this flag are enabled by default.
8814
8815**Diagnostic text:**
8816
8817+------------------------------------------------------------------------------------------------------------------------------+
8818|:warning:`warning:` |nbsp| :diagtext:`OpenMP only allows an ordered construct with the simd clause nested in a simd construct`|
8819+------------------------------------------------------------------------------------------------------------------------------+
8820
8821+------------------------------------------------------------------------------+
8822|:warning:`warning:` |nbsp| :diagtext:`unexpected '#pragma omp ...' in program`|
8823+------------------------------------------------------------------------------+
8824
8825
8826-Wspir-compat
8827-------------
8828**Diagnostic text:**
8829
8830+----------------------------------------------------------------------------------------------------------------------+
8831|:warning:`warning:` |nbsp| :diagtext:`sampler initializer has invalid` |nbsp| :placeholder:`A` |nbsp| :diagtext:`bits`|
8832+----------------------------------------------------------------------------------------------------------------------+
8833
8834
8835-Wstack-protector
8836-----------------
8837This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8838
8839-Wstatic-float-init
8840-------------------
8841This diagnostic is enabled by default.
8842
8843Also controls `-Wgnu-static-float-init`_.
8844
8845**Diagnostic text:**
8846
8847+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8848|:error:`error:` |nbsp| :diagtext:`in-class initializer for static data member of type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`requires 'constexpr' specifier`|
8849+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8850
8851
8852-Wstatic-in-inline
8853------------------
8854Some of the diagnostics controlled by this flag are enabled by default.
8855
8856**Diagnostic text:**
8857
8858+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
8859|:warning:`warning:` |nbsp| :diagtext:`static` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`is used in an inline function with external linkage`|
8860| ||:diagtext:`function`|| |
8861| |+--------------------+| |
8862| ||:diagtext:`variable`|| |
8863| |+--------------------+| |
8864+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
8865
8866+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
8867|:warning:`warning:` |nbsp| :diagtext:`static` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`is used in an inline function with external linkage`|
8868| ||:diagtext:`function`|| |
8869| |+--------------------+| |
8870| ||:diagtext:`variable`|| |
8871| |+--------------------+| |
8872+-----------------------------------------------------+----------------------+-----------------------------------------------------------------------------------------------+
8873
8874
8875-Wstatic-inline-explicit-instantiation
8876--------------------------------------
8877This diagnostic is enabled by default.
8878
8879**Diagnostic text:**
8880
8881+-------------------------------------------------+--------------------+--------------------------------------------------------+
8882|:warning:`warning:` |nbsp| :diagtext:`ignoring '`|+------------------+|:diagtext:`' keyword on explicit template instantiation`|
8883| ||:diagtext:`static`|| |
8884| |+------------------+| |
8885| ||:diagtext:`inline`|| |
8886| |+------------------+| |
8887+-------------------------------------------------+--------------------+--------------------------------------------------------+
8888
8889
8890-Wstatic-local-in-inline
8891------------------------
8892This diagnostic is enabled by default.
8893
8894**Diagnostic text:**
8895
8896+--------------------------------------------------------------------------------------------------------------------------------+
8897|:warning:`warning:` |nbsp| :diagtext:`non-constant static local variable in inline function may be different in different files`|
8898+--------------------------------------------------------------------------------------------------------------------------------+
8899
8900
8901-Wstatic-self-init
8902------------------
8903This diagnostic is enabled by default.
8904
8905**Diagnostic text:**
8906
8907+----------------------------------------------------------------------------------------------------------------------------------------------------+
8908|:warning:`warning:` |nbsp| :diagtext:`static variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is suspiciously used within its own initialization`|
8909+----------------------------------------------------------------------------------------------------------------------------------------------------+
8910
8911
8912-Wstrict-aliasing
8913-----------------
8914This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8915
8916-Wstrict-aliasing=0
8917-------------------
8918This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8919
8920-Wstrict-aliasing=1
8921-------------------
8922This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8923
8924-Wstrict-aliasing=2
8925-------------------
8926This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8927
8928-Wstrict-overflow
8929-----------------
8930This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8931
8932-Wstrict-overflow=0
8933-------------------
8934This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8935
8936-Wstrict-overflow=1
8937-------------------
8938This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8939
8940-Wstrict-overflow=2
8941-------------------
8942This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8943
8944-Wstrict-overflow=3
8945-------------------
8946This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8947
8948-Wstrict-overflow=4
8949-------------------
8950This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8951
8952-Wstrict-overflow=5
8953-------------------
8954This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8955
8956-Wstrict-prototypes
8957-------------------
8958This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
8959
8960-Wstrict-selector-match
8961-----------------------
8962**Diagnostic text:**
8963
8964+--------------------------------------------------------------------------------------------------------------+
8965|:warning:`warning:` |nbsp| :diagtext:`multiple methods named` |nbsp| :placeholder:`A` |nbsp| :diagtext:`found`|
8966+--------------------------------------------------------------------------------------------------------------+
8967
8968
8969-Wstring-compare
8970----------------
8971This diagnostic is enabled by default.
8972
8973**Diagnostic text:**
8974
8975+---------------------------------------------------------------------------+------------------------------+--------------------------------------------------------+
8976|:warning:`warning:` |nbsp| :diagtext:`result of comparison against` |nbsp| |+----------------------------+| |nbsp| :diagtext:`is unspecified (use strncmp instead)`|
8977| ||:diagtext:`a string literal`|| |
8978| |+----------------------------+| |
8979| ||:diagtext:`@encode` || |
8980| |+----------------------------+| |
8981+---------------------------------------------------------------------------+------------------------------+--------------------------------------------------------+
8982
8983
8984-Wstring-conversion
8985-------------------
8986**Diagnostic text:**
8987
8988+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8989|:warning:`warning:` |nbsp| :diagtext:`implicit conversion turns string literal into bool:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`|
8990+----------------------------------------------------------------------------------------------------------------------------------------------------------------+
8991
8992
8993-Wstring-plus-char
8994------------------
8995This diagnostic is enabled by default.
8996
8997**Diagnostic text:**
8998
8999+------------------------------------------------------------------------------------------------------------------------------------------+
9000|:warning:`warning:` |nbsp| :diagtext:`adding` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to a string pointer does not append to the string`|
9001+------------------------------------------------------------------------------------------------------------------------------------------+
9002
9003
9004-Wstring-plus-int
9005-----------------
9006This diagnostic is enabled by default.
9007
9008**Diagnostic text:**
9009
9010+----------------------------------------------------------------------------------------------------------------------------------+
9011|:warning:`warning:` |nbsp| :diagtext:`adding` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to a string does not append to the string`|
9012+----------------------------------------------------------------------------------------------------------------------------------+
9013
9014
9015-Wstrlcpy-strlcat-size
9016----------------------
9017This diagnostic is enabled by default.
9018
9019**Diagnostic text:**
9020
9021+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9022|:warning:`warning:` |nbsp| :diagtext:`size argument in` |nbsp| :placeholder:`A` |nbsp| :diagtext:`call appears to be size of the source; expected the size of the destination`|
9023+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9024
9025
9026-Wstrncat-size
9027--------------
9028This diagnostic is enabled by default.
9029
9030**Diagnostic text:**
9031
9032+--------------------------------------------------------------------------------------------------------------------------------+
9033|:warning:`warning:` |nbsp| :diagtext:`the value of the size argument in 'strncat' is too large, might lead to a buffer overflow`|
9034+--------------------------------------------------------------------------------------------------------------------------------+
9035
9036+-------------------------------------------------------------------------------------------------------+
9037|:warning:`warning:` |nbsp| :diagtext:`size argument in 'strncat' call appears to be size of the source`|
9038+-------------------------------------------------------------------------------------------------------+
9039
9040+-------------------------------------------------------------------------------------------+
9041|:warning:`warning:` |nbsp| :diagtext:`the value of the size argument to 'strncat' is wrong`|
9042+-------------------------------------------------------------------------------------------+
9043
9044
9045-Wsuper-class-method-mismatch
9046-----------------------------
9047**Diagnostic text:**
9048
9049+--------------------------------------------------------------------------------------------------------------------------------+
9050|:warning:`warning:` |nbsp| :diagtext:`method parameter type` |nbsp| :diagtext:`does not match super class method parameter type`|
9051+--------------------------------------------------------------------------------------------------------------------------------+
9052
9053
9054-Wswitch
9055--------
9056This diagnostic is enabled by default.
9057
9058**Diagnostic text:**
9059
9060+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9061|:warning:`warning:` |nbsp| :diagtext:`overflow converting case value to switch condition type (`:placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B`:diagtext:`)`|
9062+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9063
9064+---------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9065|:warning:`warning:` |nbsp| |+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9066| ||+-----------------------------------------------------------------------------------------------+ ||
9067| |||:diagtext:`:enumeration value` |nbsp| :placeholder:`B` |nbsp| :diagtext:`not handled in switch`| ||
9068| ||+-----------------------------------------------------------------------------------------------+ ||
9069| |+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9070| ||+-----------------------------------------------------------------------------------------------------------------------------------------------+ ||
9071| |||:diagtext:`:enumeration values` |nbsp| :placeholder:`B` |nbsp| :diagtext:`and` |nbsp| :placeholder:`C` |nbsp| :diagtext:`not handled in switch`| ||
9072| ||+-----------------------------------------------------------------------------------------------------------------------------------------------+ ||
9073| |+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9074| ||+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9075| |||:diagtext:`:enumeration values` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`, and` |nbsp| :placeholder:`D` |nbsp| :diagtext:`not handled in switch`| ||
9076| ||+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9077| |+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9078| ||+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+||
9079| |||:diagtext:`:`:placeholder:`A` |nbsp| :diagtext:`enumeration values not handled in switch:` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`,` |nbsp| :placeholder:`D`:diagtext:`...`|||
9080| ||+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+||
9081| |+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9082+---------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9083
9084+------------------------------------------------------------------------------------------------+
9085|:warning:`warning:` |nbsp| :diagtext:`case value not in enumerated type` |nbsp| :placeholder:`A`|
9086+------------------------------------------------------------------------------------------------+
9087
9088
9089-Wswitch-bool
9090-------------
9091This diagnostic is enabled by default.
9092
9093**Diagnostic text:**
9094
9095+-------------------------------------------------------------------------+
9096|:warning:`warning:` |nbsp| :diagtext:`switch condition has boolean value`|
9097+-------------------------------------------------------------------------+
9098
9099
9100-Wswitch-default
9101----------------
9102This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
9103
9104-Wswitch-enum
9105-------------
9106**Diagnostic text:**
9107
9108+---------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9109|:warning:`warning:` |nbsp| |+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9110| ||+----------------------------------------------------------------------------------------------------------+ ||
9111| |||:diagtext:`:enumeration value` |nbsp| :placeholder:`B` |nbsp| :diagtext:`not explicitly handled in switch`| ||
9112| ||+----------------------------------------------------------------------------------------------------------+ ||
9113| |+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9114| ||+----------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9115| |||:diagtext:`:enumeration values` |nbsp| :placeholder:`B` |nbsp| :diagtext:`and` |nbsp| :placeholder:`C` |nbsp| :diagtext:`not explicitly handled in switch`| ||
9116| ||+----------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9117| |+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9118| ||+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9119| |||:diagtext:`:enumeration values` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`, and` |nbsp| :placeholder:`D` |nbsp| :diagtext:`not explicitly handled in switch`| ||
9120| ||+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ||
9121| |+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9122| ||+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+||
9123| |||:diagtext:`:`:placeholder:`A` |nbsp| :diagtext:`enumeration values not explicitly handled in switch:` |nbsp| :placeholder:`B`:diagtext:`,` |nbsp| :placeholder:`C`:diagtext:`,` |nbsp| :placeholder:`D`:diagtext:`...`|||
9124| ||+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+||
9125| |+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+|
9126+---------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9127
9128
9129-Wsync-fetch-and-nand-semantics-changed
9130---------------------------------------
9131This diagnostic is enabled by default.
9132
9133**Diagnostic text:**
9134
9135+-------------------------------------------------------------------------------------------------------------------------------------------+
9136|:warning:`warning:` |nbsp| :diagtext:`the semantics of this intrinsic changed with GCC version 4.4 - the newer semantics are provided here`|
9137+-------------------------------------------------------------------------------------------------------------------------------------------+
9138
9139
9140-Wsynth
9141-------
9142This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
9143
9144-Wtautological-compare
9145----------------------
9146Some of the diagnostics controlled by this flag are enabled by default.
9147
9148Also controls `-Wtautological-constant-out-of-range-compare`_, `-Wtautological-pointer-compare`_, `-Wtautological-overlap-compare`_, `-Wtautological-undefined-compare`_.
9149
9150**Diagnostic text:**
9151
9152+---------------------------+---------------------------+--------------------------------------------------+------------------------+
9153|:warning:`warning:` |nbsp| |+-------------------------+|:diagtext:`comparison always evaluates to` |nbsp| |+----------------------+|
9154| ||:diagtext:`self-` || ||:diagtext:`false` ||
9155| |+-------------------------+| |+----------------------+|
9156| ||:diagtext:`array` |nbsp| || ||:diagtext:`true` ||
9157| |+-------------------------+| |+----------------------+|
9158| | | ||:diagtext:`a constant`||
9159| | | |+----------------------+|
9160+---------------------------+---------------------------+--------------------------------------------------+------------------------+
9161
9162+-------------------------------------------------------------------------------------+-------------------+
9163|:warning:`warning:` |nbsp| :diagtext:`bitwise comparison always evaluates to` |nbsp| |+-----------------+|
9164| ||:diagtext:`false`||
9165| |+-----------------+|
9166| ||:diagtext:`true` ||
9167| |+-----------------+|
9168+-------------------------------------------------------------------------------------+-------------------+
9169
9170+-------------------------------------------------------------+--------------------------+-----------------------------------------------------------------------------------------------------------+
9171|:warning:`warning:` |nbsp| :diagtext:`comparison of unsigned`|+------------------------+| |nbsp| :diagtext:`expression` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is always` |nbsp| :placeholder:`B`|
9172| || || |
9173| |+------------------------+| |
9174| || |nbsp| :diagtext:`enum`|| |
9175| |+------------------------+| |
9176+-------------------------------------------------------------+--------------------------+-----------------------------------------------------------------------------------------------------------+
9177
9178+--------------------------------------------------------------------------------------------------------+--------------------------+----------------------------------------------------------------+
9179|:warning:`warning:` |nbsp| :diagtext:`comparison of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`unsigned`|+------------------------+| |nbsp| :diagtext:`expression is always` |nbsp| :placeholder:`B`|
9180| || || |
9181| |+------------------------+| |
9182| || |nbsp| :diagtext:`enum`|| |
9183| |+------------------------+| |
9184+--------------------------------------------------------------------------------------------------------+--------------------------+----------------------------------------------------------------+
9185
9186
9187-Wtautological-constant-out-of-range-compare
9188--------------------------------------------
9189This diagnostic is enabled by default.
9190
9191**Diagnostic text:**
9192
9193+------------------------------------------------------------+------------------------------------------------+--------------------------------+----------------------------------------------------------+-------------------------------------+-------------------+
9194|:warning:`warning:` |nbsp| :diagtext:`comparison of` |nbsp| |+----------------------------------------------+| |nbsp| :diagtext:`with` |nbsp| |+--------------------------------------------------------+| |nbsp| :diagtext:`is always` |nbsp| |+-----------------+|
9195| ||+--------------------------------------------+|| ||+------------------------------------------------------+|| ||:diagtext:`false`||
9196| |||:diagtext:`constant` |nbsp| :placeholder:`A`||| |||:diagtext:`expression of type` |nbsp| :placeholder:`C`||| |+-----------------+|
9197| ||+--------------------------------------------+|| ||+------------------------------------------------------+|| ||:diagtext:`true` ||
9198| |+----------------------------------------------+| |+--------------------------------------------------------+| |+-----------------+|
9199| ||:diagtext:`true` || ||:diagtext:`boolean expression` || | |
9200| |+----------------------------------------------+| |+--------------------------------------------------------+| | |
9201| ||:diagtext:`false` || | | | |
9202| |+----------------------------------------------+| | | | |
9203+------------------------------------------------------------+------------------------------------------------+--------------------------------+----------------------------------------------------------+-------------------------------------+-------------------+
9204
9205
9206-Wtautological-overlap-compare
9207------------------------------
9208**Diagnostic text:**
9209
9210+-----------------------------------------------------------------------------------------+-------------------+
9211|:warning:`warning:` |nbsp| :diagtext:`overlapping comparisons always evaluate to` |nbsp| |+-----------------+|
9212| ||:diagtext:`false`||
9213| |+-----------------+|
9214| ||:diagtext:`true` ||
9215| |+-----------------+|
9216+-----------------------------------------------------------------------------------------+-------------------+
9217
9218
9219-Wtautological-pointer-compare
9220------------------------------
9221This diagnostic is enabled by default.
9222
9223**Diagnostic text:**
9224
9225+--------------------------------------------------------------------+---------------------------+----------------------------------------------------------+-------------------------+----------------------------------------+-------------------+--------------------------------+
9226|:warning:`warning:` |nbsp| :diagtext:`comparison of nonnull` |nbsp| |+-------------------------+| |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`'` |nbsp| |+-----------------------+|:diagtext:`equal to a null pointer is '`|+-----------------+|:diagtext:`' on first encounter`|
9227| ||:diagtext:`function call`|| ||:diagtext:`not` |nbsp| || ||:diagtext:`true` || |
9228| |+-------------------------+| |+-----------------------+| |+-----------------+| |
9229| ||:diagtext:`parameter` || || || ||:diagtext:`false`|| |
9230| |+-------------------------+| |+-----------------------+| |+-----------------+| |
9231+--------------------------------------------------------------------+---------------------------+----------------------------------------------------------+-------------------------+----------------------------------------+-------------------+--------------------------------+
9232
9233+------------------------------------------------------------+------------------------+----------------------------------------------------------+-------------------------+-----------------------------------------------------+-------------------+
9234|:warning:`warning:` |nbsp| :diagtext:`comparison of` |nbsp| |+----------------------+| |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`'` |nbsp| |+-----------------------+|:diagtext:`equal to a null pointer is always` |nbsp| |+-----------------+|
9235| ||:diagtext:`address of`|| ||:diagtext:`not` |nbsp| || ||:diagtext:`true` ||
9236| |+----------------------+| |+-----------------------+| |+-----------------+|
9237| ||:diagtext:`function` || || || ||:diagtext:`false`||
9238| |+----------------------+| |+-----------------------+| |+-----------------+|
9239| ||:diagtext:`array` || | | | |
9240| |+----------------------+| | | | |
9241+------------------------------------------------------------+------------------------+----------------------------------------------------------+-------------------------+-----------------------------------------------------+-------------------+
9242
9243
9244-Wtautological-undefined-compare
9245--------------------------------
9246This diagnostic is enabled by default.
9247
9248**Diagnostic text:**
9249
9250+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------+
9251|:warning:`warning:` |nbsp| :diagtext:`reference cannot be bound to dereferenced null pointer in well-defined C++ code; comparison may be assumed to always evaluate to` |nbsp| |+-----------------+|
9252| ||:diagtext:`true` ||
9253| |+-----------------+|
9254| ||:diagtext:`false`||
9255| |+-----------------+|
9256+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------+
9257
9258+------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------+
9259|:warning:`warning:` |nbsp| :diagtext:`'this' pointer cannot be null in well-defined C++ code; comparison may be assumed to always evaluate to` |nbsp| |+-----------------+|
9260| ||:diagtext:`true` ||
9261| |+-----------------+|
9262| ||:diagtext:`false`||
9263| |+-----------------+|
9264+------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------+
9265
9266
9267-Wtentative-definition-incomplete-type
9268--------------------------------------
9269This diagnostic is enabled by default.
9270
9271**Diagnostic text:**
9272
9273+---------------------------------------------------------------------------------------------------------------------------------------------------+
9274|:warning:`warning:` |nbsp| :diagtext:`tentative definition of variable with internal linkage has incomplete non-array type` |nbsp| :placeholder:`A`|
9275+---------------------------------------------------------------------------------------------------------------------------------------------------+
9276
9277
9278-Wthread-safety
9279---------------
9280Controls `-Wthread-safety-attributes`_, `-Wthread-safety-analysis`_, `-Wthread-safety-precise`_, `-Wthread-safety-reference`_.
9281
9282
9283-Wthread-safety-analysis
9284------------------------
9285**Diagnostic text:**
9286
9287+----------------------------------------------------------------------------------------------------------------------------------------------------+
9288|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' must be acquired before '`:placeholder:`C`:diagtext:`'`|
9289+----------------------------------------------------------------------------------------------------------------------------------------------------+
9290
9291+---------------------------------------------------------------------------------------------------------------------------------+
9292|:warning:`warning:` |nbsp| :diagtext:`Cycle in acquired\_before/after dependencies, starting with '`:placeholder:`A`:diagtext:`'`|
9293+---------------------------------------------------------------------------------------------------------------------------------+
9294
9295+---------------------------------------------------------------------+
9296|:warning:`warning:` |nbsp| :diagtext:`cannot resolve lock expression`|
9297+---------------------------------------------------------------------+
9298
9299+-----------------------------------------------------------------------------------------------------------------------------------------------+
9300|:warning:`warning:` |nbsp| :diagtext:`acquiring` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' that is already held`|
9301+-----------------------------------------------------------------------------------------------------------------------------------------------+
9302
9303+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
9304|:warning:`warning:` |nbsp| :diagtext:`expecting` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' to be held at start of each loop`|
9305+-----------------------------------------------------------------------------------------------------------------------------------------------------------+
9306
9307+------------------------------------------------------------------------------------------------------------------------------------------------------------+
9308|:warning:`warning:` |nbsp| :diagtext:`expecting` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' to be held at the end of function`|
9309+------------------------------------------------------------------------------------------------------------------------------------------------------------+
9310
9311+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9312|:warning:`warning:` |nbsp| :diagtext:`cannot call function '`:placeholder:`B`:diagtext:`' while` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`C`:diagtext:`' is held`|
9313+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9314
9315+---------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9316|:warning:`warning:` |nbsp| :diagtext:`calling function '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9317| ||+------------------------------------------+ ||
9318| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9319| ||+------------------------------------------+ ||
9320| |+--------------------------------------------------------+|
9321| ||+------------------------------------------------------+||
9322| |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9323| ||+------------------------------------------------------+||
9324| |+--------------------------------------------------------+|
9325+---------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9326
9327+--------------------------------------------------------------------------------------------------------------------------------------------------+
9328|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' is acquired exclusively and shared in the same scope`|
9329+--------------------------------------------------------------------------------------------------------------------------------------------------+
9330
9331+------------------------------------------------------------------------------------------------------------------------------------+
9332|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' is not held on every path through here`|
9333+------------------------------------------------------------------------------------------------------------------------------------+
9334
9335+----------------------------------------------------------------------------------------------------------------------------------+
9336|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' is still held at the end of function`|
9337+----------------------------------------------------------------------------------------------------------------------------------+
9338
9339+--------------------------------------------------------------------------------------------------------------------------------------------+
9340|:warning:`warning:` |nbsp| :diagtext:`releasing` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' that was not held`|
9341+--------------------------------------------------------------------------------------------------------------------------------------------+
9342
9343+----------------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------------+-----------------------+--------------------------+
9344|:warning:`warning:` |nbsp| :diagtext:`releasing` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' using` |nbsp| |+---------------------+| |nbsp| :diagtext:`access, expected` |nbsp| |+---------------------+| |nbsp| :diagtext:`access`|
9345| ||:diagtext:`shared` || ||:diagtext:`shared` || |
9346| |+---------------------+| |+---------------------+| |
9347| ||:diagtext:`exclusive`|| ||:diagtext:`exclusive`|| |
9348| |+---------------------+| |+---------------------+| |
9349+----------------------------------------------------------------------------------------------------------------------------------------+-----------------------+--------------------------------------------+-----------------------+--------------------------+
9350
9351+---------------------------+---------------------+---------------------------------------------------------------------------------------------------+-----------------------------------+
9352|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`the value pointed to by '`:placeholder:`A`:diagtext:`' requires holding` |nbsp| |+---------------------------------+|
9353| ||:diagtext:`reading`|| ||:diagtext:`any mutex` ||
9354| |+-------------------+| |+---------------------------------+|
9355| ||:diagtext:`writing`|| ||:diagtext:`any mutex exclusively`||
9356| |+-------------------+| |+---------------------------------+|
9357+---------------------------+---------------------+---------------------------------------------------------------------------------------------------+-----------------------------------+
9358
9359+---------------------------+---------------------+---------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9360|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`the value pointed to by '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9361| ||:diagtext:`reading`|| ||+------------------------------------------+ ||
9362| |+-------------------+| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9363| ||:diagtext:`writing`|| ||+------------------------------------------+ ||
9364| |+-------------------+| |+--------------------------------------------------------+|
9365| | | ||+------------------------------------------------------+||
9366| | | |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9367| | | ||+------------------------------------------------------+||
9368| | | |+--------------------------------------------------------+|
9369+---------------------------+---------------------+---------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9370
9371+---------------------------+---------------------+------------------------------------------------------------------------------------+-----------------------------------+
9372|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`variable '`:placeholder:`A`:diagtext:`' requires holding` |nbsp| |+---------------------------------+|
9373| ||:diagtext:`reading`|| ||:diagtext:`any mutex` ||
9374| |+-------------------+| |+---------------------------------+|
9375| ||:diagtext:`writing`|| ||:diagtext:`any mutex exclusively`||
9376| |+-------------------+| |+---------------------------------+|
9377+---------------------------+---------------------+------------------------------------------------------------------------------------+-----------------------------------+
9378
9379+---------------------------+---------------------+------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9380|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`variable '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9381| ||:diagtext:`reading`|| ||+------------------------------------------+ ||
9382| |+-------------------+| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9383| ||:diagtext:`writing`|| ||+------------------------------------------+ ||
9384| |+-------------------+| |+--------------------------------------------------------+|
9385| | | ||+------------------------------------------------------+||
9386| | | |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9387| | | ||+------------------------------------------------------+||
9388| | | |+--------------------------------------------------------+|
9389+---------------------------+---------------------+------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9390
9391
9392-Wthread-safety-attributes
9393--------------------------
9394**Diagnostic text:**
9395
9396+----------------------------------------------------------------------------------------------------------------------------------------+
9397|:warning:`warning:` |nbsp| :diagtext:`invalid capability name '`:placeholder:`A`:diagtext:`'; capability name must be 'mutex' or 'role'`|
9398+----------------------------------------------------------------------------------------------------------------------------------------+
9399
9400+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9401|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute requires arguments whose type is annotated with 'capability' attribute; type here is` |nbsp| :placeholder:`B`|
9402+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9403
9404+--------------------------------------------------------------------------------------------------------------------------------------------------------+
9405|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute can only be applied in a context annotated with 'capability("mutex")' attribute`|
9406+--------------------------------------------------------------------------------------------------------------------------------------------------------+
9407
9408+----------------------------------------------------------------------------------------------------------------------------------+
9409|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`only applies to pointer types; type here is` |nbsp| :placeholder:`B`|
9410+----------------------------------------------------------------------------------------------------------------------------------+
9411
9412+------------------------------------------------------------------------------------------------------------------------------------+
9413|:warning:`warning:` |nbsp| :diagtext:`ignoring` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute because its argument is invalid`|
9414+------------------------------------------------------------------------------------------------------------------------------------+
9415
9416
9417-Wthread-safety-beta
9418--------------------
9419**Diagnostic text:**
9420
9421+------------------------------------------------------------------+
9422|:warning:`warning:` |nbsp| :diagtext:`Thread safety beta warning.`|
9423+------------------------------------------------------------------+
9424
9425
9426-Wthread-safety-negative
9427------------------------
9428**Diagnostic text:**
9429
9430+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9431|:warning:`warning:` |nbsp| :diagtext:`acquiring` |nbsp| :placeholder:`A` |nbsp| :diagtext:`'`:placeholder:`B`:diagtext:`' requires negative capability '`:placeholder:`C`:diagtext:`'`|
9432+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9433
9434
9435-Wthread-safety-precise
9436-----------------------
9437**Diagnostic text:**
9438
9439+---------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9440|:warning:`warning:` |nbsp| :diagtext:`calling function '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9441| ||+------------------------------------------+ ||
9442| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9443| ||+------------------------------------------+ ||
9444| |+--------------------------------------------------------+|
9445| ||+------------------------------------------------------+||
9446| |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9447| ||+------------------------------------------------------+||
9448| |+--------------------------------------------------------+|
9449+---------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9450
9451+---------------------------+---------------------+---------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9452|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`the value pointed to by '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9453| ||:diagtext:`reading`|| ||+------------------------------------------+ ||
9454| |+-------------------+| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9455| ||:diagtext:`writing`|| ||+------------------------------------------+ ||
9456| |+-------------------+| |+--------------------------------------------------------+|
9457| | | ||+------------------------------------------------------+||
9458| | | |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9459| | | ||+------------------------------------------------------+||
9460| | | |+--------------------------------------------------------+|
9461+---------------------------+---------------------+---------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9462
9463+---------------------------+---------------------+------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9464|:warning:`warning:` |nbsp| |+-------------------+| |nbsp| :diagtext:`variable '`:placeholder:`B`:diagtext:`' requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9465| ||:diagtext:`reading`|| ||+------------------------------------------+ ||
9466| |+-------------------+| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9467| ||:diagtext:`writing`|| ||+------------------------------------------+ ||
9468| |+-------------------+| |+--------------------------------------------------------+|
9469| | | ||+------------------------------------------------------+||
9470| | | |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9471| | | ||+------------------------------------------------------+||
9472| | | |+--------------------------------------------------------+|
9473+---------------------------+---------------------+------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9474
9475
9476-Wthread-safety-reference
9477-------------------------
9478**Diagnostic text:**
9479
9480+----------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9481|:warning:`warning:` |nbsp| :diagtext:`passing variable '`:placeholder:`B`:diagtext:`' by reference requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9482| ||+------------------------------------------+ ||
9483| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9484| ||+------------------------------------------+ ||
9485| |+--------------------------------------------------------+|
9486| ||+------------------------------------------------------+||
9487| |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9488| ||+------------------------------------------------------+||
9489| |+--------------------------------------------------------+|
9490+----------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9491
9492+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9493|:warning:`warning:` |nbsp| :diagtext:`passing the value that '`:placeholder:`B`:diagtext:`' points to by reference requires holding` |nbsp| :placeholder:`A` |nbsp| |+--------------------------------------------------------+|
9494| ||+------------------------------------------+ ||
9495| |||:diagtext:`'`:placeholder:`C`:diagtext:`'`| ||
9496| ||+------------------------------------------+ ||
9497| |+--------------------------------------------------------+|
9498| ||+------------------------------------------------------+||
9499| |||:diagtext:`'`:placeholder:`C`:diagtext:`' exclusively`|||
9500| ||+------------------------------------------------------+||
9501| |+--------------------------------------------------------+|
9502+--------------------------------------------------------------------------------------------------------------------------------------------------------------------+----------------------------------------------------------+
9503
9504
9505-Wthread-safety-verbose
9506-----------------------
9507**Diagnostic text:**
9508
9509+---------------------------------------------------------------------+
9510|:warning:`warning:` |nbsp| :diagtext:`Thread safety verbose warning.`|
9511+---------------------------------------------------------------------+
9512
9513
9514-Wtrigraphs
9515-----------
9516This diagnostic is enabled by default.
9517
9518**Diagnostic text:**
9519
9520+-----------------------------------------------------------------------------------------------------+
9521|:warning:`warning:` |nbsp| :diagtext:`trigraph converted to '`:placeholder:`A`:diagtext:`' character`|
9522+-----------------------------------------------------------------------------------------------------+
9523
9524+------------------------------------------------------------------+
9525|:warning:`warning:` |nbsp| :diagtext:`trigraph ends block comment`|
9526+------------------------------------------------------------------+
9527
9528+-------------------------------------------------------+
9529|:warning:`warning:` |nbsp| :diagtext:`trigraph ignored`|
9530+-------------------------------------------------------+
9531
9532+-------------------------------------------------------------------------------+
9533|:warning:`warning:` |nbsp| :diagtext:`ignored trigraph would end block comment`|
9534+-------------------------------------------------------------------------------+
9535
9536
9537-Wtype-limits
9538-------------
9539This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
9540
9541-Wtype-safety
9542-------------
9543This diagnostic is enabled by default.
9544
9545**Diagnostic text:**
9546
9547+----------------------------------------------------------------------------------------------------------------------------+
9548|:warning:`warning:` |nbsp| :diagtext:`specified` |nbsp| :placeholder:`A` |nbsp| :diagtext:`type tag requires a null pointer`|
9549+----------------------------------------------------------------------------------------------------------------------------+
9550
9551+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------+
9552|:warning:`warning:` |nbsp| :diagtext:`argument type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`doesn't match specified` |nbsp| :placeholder:`B` |nbsp| :diagtext:`type tag` |nbsp| |+---------------------------------------------------+|
9553| ||+-------------------------------------------------+||
9554| |||:diagtext:`that requires` |nbsp| :placeholder:`D`|||
9555| ||+-------------------------------------------------+||
9556| |+---------------------------------------------------+|
9557| || ||
9558| |+---------------------------------------------------+|
9559+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------------------------------------------+
9560
9561+---------------------------------------------------------------------------------------------------+
9562|:warning:`warning:` |nbsp| :diagtext:`this type tag was not designed to be used with this function`|
9563+---------------------------------------------------------------------------------------------------+
9564
9565
9566-Wtypedef-redefinition
9567----------------------
9568This diagnostic is enabled by default.
9569
9570**Diagnostic text:**
9571
9572+--------------------------------------------------------------------------------------------------------------------------+
9573|:warning:`warning:` |nbsp| :diagtext:`redefinition of typedef` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is a C11 feature`|
9574+--------------------------------------------------------------------------------------------------------------------------+
9575
9576
9577-Wtypename-missing
9578------------------
9579This diagnostic is enabled by default.
9580
9581**Diagnostic text:**
9582
9583+-------------------------------------------------------------------------------------------------------------------------------------+
9584|:warning:`warning:` |nbsp| :diagtext:`missing 'typename' prior to dependent type name '`:placeholder:`A`:placeholder:`B`:diagtext:`'`|
9585+-------------------------------------------------------------------------------------------------------------------------------------+
9586
9587
9588-Wunavailable-declarations
9589--------------------------
9590This diagnostic is enabled by default.
9591
9592**Diagnostic text:**
9593
9594+----------------------------------------------------------------------------------------------------------------------+
9595|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may be unavailable because the receiver type is unknown`|
9596+----------------------------------------------------------------------------------------------------------------------+
9597
9598
9599-Wundeclared-selector
9600---------------------
9601**Diagnostic text:**
9602
9603+----------------------------------------------------------------------------------+
9604|:warning:`warning:` |nbsp| :diagtext:`undeclared selector` |nbsp| :placeholder:`A`|
9605+----------------------------------------------------------------------------------+
9606
9607+-------------------------------------------------------------------------------------------------------------------------------------------------+
9608|:warning:`warning:` |nbsp| :diagtext:`undeclared selector` |nbsp| :placeholder:`A`:diagtext:`; did you mean` |nbsp| :placeholder:`B`:diagtext:`?`|
9609+-------------------------------------------------------------------------------------------------------------------------------------------------+
9610
9611
9612-Wundef
9613-------
9614**Diagnostic text:**
9615
9616+---------------------------------------------------------------------------------------------+
9617|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not defined, evaluates to 0`|
9618+---------------------------------------------------------------------------------------------+
9619
9620
9621-Wundefined-bool-conversion
9622---------------------------
9623This diagnostic is enabled by default.
9624
9625**Diagnostic text:**
9626
9627+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9628|:warning:`warning:` |nbsp| :diagtext:`reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed to always convert to true`|
9629+------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9630
9631+-----------------------------------------------------------------------------------------------------------------------------------------------+
9632|:warning:`warning:` |nbsp| :diagtext:`'this' pointer cannot be null in well-defined C++ code; pointer may be assumed to always convert to true`|
9633+-----------------------------------------------------------------------------------------------------------------------------------------------+
9634
9635
9636-Wundefined-func-template
9637-------------------------
9638**Diagnostic text:**
9639
9640+---------------------------------------------------------------------------------------------------------------------------------------------------------+
9641|:warning:`warning:` |nbsp| :diagtext:`instantiation of function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`required here, but no definition is available`|
9642+---------------------------------------------------------------------------------------------------------------------------------------------------------+
9643
9644
9645-Wundefined-inline
9646------------------
9647This diagnostic is enabled by default.
9648
9649**Diagnostic text:**
9650
9651+----------------------------------------------------------------------------------------------------------------+
9652|:warning:`warning:` |nbsp| :diagtext:`inline function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not defined`|
9653+----------------------------------------------------------------------------------------------------------------+
9654
9655
9656-Wundefined-internal
9657--------------------
9658This diagnostic is enabled by default.
9659
9660**Diagnostic text:**
9661
9662+---------------------------+----------------------+-----------------------------------------------------------------------------------+
9663|:warning:`warning:` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`has internal linkage but is not defined`|
9664| ||:diagtext:`function`|| |
9665| |+--------------------+| |
9666| ||:diagtext:`variable`|| |
9667| |+--------------------+| |
9668+---------------------------+----------------------+-----------------------------------------------------------------------------------+
9669
9670
9671-Wundefined-reinterpret-cast
9672----------------------------
9673**Diagnostic text:**
9674
9675+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9676|:warning:`warning:` |nbsp| :diagtext:`dereference of type` |nbsp| :placeholder:`B` |nbsp| :diagtext:`that was reinterpret\_cast from type` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has undefined behavior`|
9677+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9678
9679+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9680|:warning:`warning:` |nbsp| :diagtext:`reinterpret\_cast from` |nbsp| :placeholder:`A` |nbsp| :diagtext:`to` |nbsp| :placeholder:`B` |nbsp| :diagtext:`has undefined behavior`|
9681+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9682
9683
9684-Wundefined-var-template
9685------------------------
9686This diagnostic is enabled by default.
9687
9688**Diagnostic text:**
9689
9690+---------------------------------------------------------------------------------------------------------------------------------------------------------+
9691|:warning:`warning:` |nbsp| :diagtext:`instantiation of variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`required here, but no definition is available`|
9692+---------------------------------------------------------------------------------------------------------------------------------------------------------+
9693
9694
9695-Wunevaluated-expression
9696------------------------
9697This diagnostic is enabled by default.
9698
9699Also controls `-Wpotentially-evaluated-expression`_.
9700
9701**Diagnostic text:**
9702
9703+-----------------------------------------------------------------------------------------------------------+
9704|:warning:`warning:` |nbsp| :diagtext:`expression with side effects has no effect in an unevaluated context`|
9705+-----------------------------------------------------------------------------------------------------------+
9706
9707
9708-Wunguarded-availability
9709------------------------
9710**Diagnostic text:**
9711
9712+----------------------------------------------------------------------------------------------+
9713|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is only available conditionally`|
9714+----------------------------------------------------------------------------------------------+
9715
9716+------------------------------------------------------------------------------------------------------------------+
9717|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`may be partial because the receiver type is unknown`|
9718+------------------------------------------------------------------------------------------------------------------+
9719
9720+--------------------------------------------------------------------------------------------------+
9721|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is partial:` |nbsp| :placeholder:`B`|
9722+--------------------------------------------------------------------------------------------------+
9723
9724+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
9725|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is only available on` |nbsp| :placeholder:`B` |nbsp| :placeholder:`C` |nbsp| :diagtext:`or newer`|
9726+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
9727
9728
9729-Wunicode
9730---------
9731This diagnostic is enabled by default.
9732
9733**Diagnostic text:**
9734
9735+-------------------------------------------------------------------------------------------------------------------+
9736|:warning:`warning:` |nbsp| :diagtext:`incomplete universal character name; treating as '\\' followed by identifier`|
9737+-------------------------------------------------------------------------------------------------------------------+
9738
9739+-------------------------------------------------------------------------------------------------------------------------------------------------------+
9740|:warning:`warning:` |nbsp| :diagtext:`\\`:placeholder:`A` |nbsp| :diagtext:`used with no following hex digits; treating as '\\' followed by identifier`|
9741+-------------------------------------------------------------------------------------------------------------------------------------------------------+
9742
9743+-----------------------------------------------------------------------------------------------+
9744|:warning:`warning:` |nbsp| :diagtext:`universal character name refers to a surrogate character`|
9745+-----------------------------------------------------------------------------------------------+
9746
9747+--------------------------------------------------------------------------------------------------------------------------------------+
9748|:warning:`warning:` |nbsp| :diagtext:`universal character names are only valid in C99 or C++; treating as '\\' followed by identifier`|
9749+--------------------------------------------------------------------------------------------------------------------------------------+
9750
9751+---------------------------------------------------------------------------------------------+
9752|:warning:`warning:` |nbsp| :diagtext:`universal character names are only valid in C99 or C++`|
9753+---------------------------------------------------------------------------------------------+
9754
9755
9756-Wunicode-whitespace
9757--------------------
9758This diagnostic is enabled by default.
9759
9760**Diagnostic text:**
9761
9762+-------------------------------------------------------------------------------+
9763|:warning:`warning:` |nbsp| :diagtext:`treating Unicode character as whitespace`|
9764+-------------------------------------------------------------------------------+
9765
9766
9767-Wuninitialized
9768---------------
9769Some of the diagnostics controlled by this flag are enabled by default.
9770
9771Also controls `-Wsometimes-uninitialized`_, `-Wstatic-self-init`_.
9772
9773**Diagnostic text:**
9774
9775+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
9776|:warning:`warning:` |nbsp| :diagtext:`base class` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is uninitialized when used here to access` |nbsp| :placeholder:`B`|
9777+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
9778
9779+-----------------------------------------------------------------------------------------------------------------------+
9780|:warning:`warning:` |nbsp| :diagtext:`field` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is uninitialized when used here`|
9781+-----------------------------------------------------------------------------------------------------------------------+
9782
9783+--------------------------------------------------------------------------------------------------------------------------------------+
9784|:warning:`warning:` |nbsp| :diagtext:`reference` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not yet bound to a value when used here`|
9785+--------------------------------------------------------------------------------------------------------------------------------------+
9786
9787+------------------------------------------------------------------------------------------------------------------------------------------------+
9788|:warning:`warning:` |nbsp| :diagtext:`block pointer variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is uninitialized when captured by block`|
9789+------------------------------------------------------------------------------------------------------------------------------------------------+
9790
9791+---------------------------------------------------------------------------------------------------------------------------------------------------+
9792|:warning:`warning:` |nbsp| :diagtext:`variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is uninitialized when used within its own initialization`|
9793+---------------------------------------------------------------------------------------------------------------------------------------------------+
9794
9795+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
9796|:warning:`warning:` |nbsp| :diagtext:`reference` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not yet bound to a value when used within its own initialization`|
9797+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
9798
9799+------------------------------------------------------------------------------------------------------------------------+-------------------------------+
9800|:warning:`warning:` |nbsp| :diagtext:`variable` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is uninitialized when` |nbsp| |+-----------------------------+|
9801| ||:diagtext:`used here` ||
9802| |+-----------------------------+|
9803| ||:diagtext:`captured by block`||
9804| |+-----------------------------+|
9805+------------------------------------------------------------------------------------------------------------------------+-------------------------------+
9806
9807
9808-Wunknown-argument
9809------------------
9810This diagnostic is enabled by default.
9811
9812**Diagnostic text:**
9813
9814+-----------------------------------------------------------------------------------------------------------+
9815|:warning:`warning:` |nbsp| :diagtext:`unknown argument ignored in clang-cl: '`:placeholder:`A`:diagtext:`'`|
9816+-----------------------------------------------------------------------------------------------------------+
9817
9818
9819-Wunknown-attributes
9820--------------------
9821This diagnostic is enabled by default.
9822
9823**Diagnostic text:**
9824
9825+-----------------------------------------------------------------------------------------------------------+
9826|:warning:`warning:` |nbsp| :diagtext:`unknown attribute` |nbsp| :placeholder:`A` |nbsp| :diagtext:`ignored`|
9827+-----------------------------------------------------------------------------------------------------------+
9828
9829
9830-Wunknown-escape-sequence
9831-------------------------
9832This diagnostic is enabled by default.
9833
9834**Diagnostic text:**
9835
9836+-----------------------------------------------------------------------------------------------+
9837|:warning:`warning:` |nbsp| :diagtext:`unknown escape sequence '\\`:placeholder:`A`:diagtext:`'`|
9838+-----------------------------------------------------------------------------------------------+
9839
9840
9841-Wunknown-pragmas
9842-----------------
9843Some of the diagnostics controlled by this flag are enabled by default.
9844
9845**Diagnostic text:**
9846
9847+------------------------------------------------------------------------------------+
9848|:warning:`warning:` |nbsp| :diagtext:`expected 'ON' or 'OFF' or 'DEFAULT' in pragma`|
9849+------------------------------------------------------------------------------------+
9850
9851+--------------------------------------------------------------------------+
9852|:warning:`warning:` |nbsp| :diagtext:`expected end of directive in pragma`|
9853+--------------------------------------------------------------------------+
9854
9855+-----------------------------------------------------------------------+
9856|:warning:`warning:` |nbsp| :diagtext:`unknown pragma in STDC namespace`|
9857+-----------------------------------------------------------------------+
9858
9859+--------------------------------------------------------------------------------------------+
9860|:warning:`warning:` |nbsp| :diagtext:`pragma diagnostic pop could not pop, no matching push`|
9861+--------------------------------------------------------------------------------------------+
9862
9863+--------------------------------------------------------------------------------------------------------------------------+
9864|:warning:`warning:` |nbsp| :diagtext:`pragma diagnostic expected 'error', 'warning', 'ignored', 'fatal', 'push', or 'pop'`|
9865+--------------------------------------------------------------------------------------------------------------------------+
9866
9867+----------------------------------------------------------------------------------------------+
9868|:warning:`warning:` |nbsp| :diagtext:`pragma diagnostic expected option name (e.g. "-Wundef")`|
9869+----------------------------------------------------------------------------------------------+
9870
9871+----------------------------------------------------------------------------+
9872|:warning:`warning:` |nbsp| :diagtext:`unexpected token in pragma diagnostic`|
9873+----------------------------------------------------------------------------+
9874
9875+----------------------------------------------------------------------------------------------------+
9876|:warning:`warning:` |nbsp| :diagtext:`unknown warning group '`:placeholder:`A`:diagtext:`', ignored`|
9877+----------------------------------------------------------------------------------------------------+
9878
9879+-------------------------------------------------------------+
9880|:warning:`warning:` |nbsp| :diagtext:`unknown pragma ignored`|
9881+-------------------------------------------------------------+
9882
9883+----------------------------------------------------------------------------------------------------+
9884|:warning:`warning:` |nbsp| :diagtext:`pragma include\_alias expected '`:placeholder:`A`:diagtext:`'`|
9885+----------------------------------------------------------------------------------------------------+
9886
9887+--------------------------------------------------------------------------------------+
9888|:warning:`warning:` |nbsp| :diagtext:`pragma include\_alias expected include filename`|
9889+--------------------------------------------------------------------------------------+
9890
9891+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9892|:warning:`warning:` |nbsp| :diagtext:`angle-bracketed include <`:placeholder:`A`:diagtext:`> cannot be aliased to double-quoted include "`:placeholder:`B`:diagtext:`"`|
9893+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9894
9895+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9896|:warning:`warning:` |nbsp| :diagtext:`double-quoted include "`:placeholder:`A`:diagtext:`" cannot be aliased to angle-bracketed include <`:placeholder:`B`:diagtext:`>`|
9897+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
9898
9899+----------------------------------------------------------------------------------------------+
9900|:warning:`warning:` |nbsp| :diagtext:`#pragma warning expected '`:placeholder:`A`:diagtext:`'`|
9901+----------------------------------------------------------------------------------------------+
9902
9903+--------------------------------------------------------------------------------+
9904|:warning:`warning:` |nbsp| :diagtext:`#pragma warning expected a warning number`|
9905+--------------------------------------------------------------------------------+
9906
9907+----------------------------------------------------------------------------------------------------+
9908|:warning:`warning:` |nbsp| :diagtext:`#pragma warning(push, level) requires a level between 0 and 4`|
9909+----------------------------------------------------------------------------------------------------+
9910
9911+-----------------------------------------------------------------------------------------------------------------------------------------------+
9912|:warning:`warning:` |nbsp| :diagtext:`#pragma warning expected 'push', 'pop', 'default', 'disable', 'error', 'once', 'suppress', 1, 2, 3, or 4`|
9913+-----------------------------------------------------------------------------------------------------------------------------------------------+
9914
9915+----------------------------------------------------------------------------------------------------+
9916|:warning:`warning:` |nbsp| :diagtext:`pragma STDC FENV\_ACCESS ON is not supported, ignoring pragma`|
9917+----------------------------------------------------------------------------------------------------+
9918
9919
9920-Wunknown-sanitizers
9921--------------------
9922This diagnostic is enabled by default.
9923
9924**Diagnostic text:**
9925
9926+-----------------------------------------------------------------------------------------------+
9927|:warning:`warning:` |nbsp| :diagtext:`unknown sanitizer '`:placeholder:`A`:diagtext:`' ignored`|
9928+-----------------------------------------------------------------------------------------------+
9929
9930
9931-Wunknown-warning-option
9932------------------------
9933This diagnostic is enabled by default.
9934
9935**Diagnostic text:**
9936
9937+------------------------------------------------------+---------------------+---------------------------------------------------------+--------------------------------------------------------------+
9938|:warning:`warning:` |nbsp| :diagtext:`unknown` |nbsp| |+-------------------+| |nbsp| :diagtext:`option '`:placeholder:`B`:diagtext:`'`|+------------------------------------------------------------+|
9939| ||:diagtext:`warning`|| || ||
9940| |+-------------------+| |+------------------------------------------------------------+|
9941| ||:diagtext:`remark` || ||+----------------------------------------------------------+||
9942| |+-------------------+| |||:diagtext:`; did you mean '`:placeholder:`D`:diagtext:`'?`|||
9943| | | ||+----------------------------------------------------------+||
9944| | | |+------------------------------------------------------------+|
9945+------------------------------------------------------+---------------------+---------------------------------------------------------+--------------------------------------------------------------+
9946
9947+-------------------------------------------------------------------------------------------------------------------------------------------+
9948|:warning:`warning:` |nbsp| :diagtext:`unknown` |nbsp| :placeholder:`A` |nbsp| :diagtext:`warning specifier: '`:placeholder:`B`:diagtext:`'`|
9949+-------------------------------------------------------------------------------------------------------------------------------------------+
9950
9951
9952-Wunnamed-type-template-args
9953----------------------------
9954Some of the diagnostics controlled by this flag are enabled by default.
9955
9956Also controls `-Wc++98-compat-unnamed-type-template-args`_.
9957
9958**Diagnostic text:**
9959
9960+--------------------------------------------------------------------------+
9961|:warning:`warning:` |nbsp| :diagtext:`template argument uses unnamed type`|
9962+--------------------------------------------------------------------------+
9963
9964
9965-Wunneeded-internal-declaration
9966-------------------------------
9967**Diagnostic text:**
9968
9969+---------------------------+----------------------+---------------------------------------------------------------------------------+
9970|:warning:`warning:` |nbsp| |+--------------------+| |nbsp| :placeholder:`B` |nbsp| :diagtext:`is not needed and will not be emitted`|
9971| ||:diagtext:`function`|| |
9972| |+--------------------+| |
9973| ||:diagtext:`variable`|| |
9974| |+--------------------+| |
9975+---------------------------+----------------------+---------------------------------------------------------------------------------+
9976
9977+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
9978|:warning:`warning:` |nbsp| :diagtext:`'static' function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`declared in header file should be declared 'static inline'`|
9979+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
9980
9981
9982-Wunneeded-member-function
9983--------------------------
9984**Diagnostic text:**
9985
9986+---------------------------------------------------------------------------------------------------------------------------------------+
9987|:warning:`warning:` |nbsp| :diagtext:`member function` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not needed and will not be emitted`|
9988+---------------------------------------------------------------------------------------------------------------------------------------+
9989
9990
9991-Wunreachable-code
9992------------------
9993Also controls `-Wunreachable-code-loop-increment`_.
9994
9995**Diagnostic text:**
9996
9997+------------------------------------------------------------------+
9998|:warning:`warning:` |nbsp| :diagtext:`code will never be executed`|
9999+------------------------------------------------------------------+
10000
10001
10002-Wunreachable-code-aggressive
10003-----------------------------
10004Controls `-Wunreachable-code`_, `-Wunreachable-code-break`_, `-Wunreachable-code-return`_.
10005
10006
10007-Wunreachable-code-break
10008------------------------
10009**Diagnostic text:**
10010
10011+---------------------------------------------------------------------+
10012|:warning:`warning:` |nbsp| :diagtext:`'break' will never be executed`|
10013+---------------------------------------------------------------------+
10014
10015
10016-Wunreachable-code-loop-increment
10017---------------------------------
10018**Diagnostic text:**
10019
10020+-------------------------------------------------------------------------------------------------+
10021|:warning:`warning:` |nbsp| :diagtext:`loop will run at most once (loop increment never executed)`|
10022+-------------------------------------------------------------------------------------------------+
10023
10024
10025-Wunreachable-code-return
10026-------------------------
10027**Diagnostic text:**
10028
10029+----------------------------------------------------------------------+
10030|:warning:`warning:` |nbsp| :diagtext:`'return' will never be executed`|
10031+----------------------------------------------------------------------+
10032
10033
10034-Wunsequenced
10035-------------
10036This diagnostic is enabled by default.
10037
10038**Diagnostic text:**
10039
10040+----------------------------------------------------------------------------------------------------+
10041|:warning:`warning:` |nbsp| :diagtext:`multiple unsequenced modifications to` |nbsp| :placeholder:`A`|
10042+----------------------------------------------------------------------------------------------------+
10043
10044+-----------------------------------------------------------------------------------------------------+
10045|:warning:`warning:` |nbsp| :diagtext:`unsequenced modification and access to` |nbsp| :placeholder:`A`|
10046+-----------------------------------------------------------------------------------------------------+
10047
10048
10049-Wunsupported-cb
10050----------------
10051This diagnostic is enabled by default.
10052
10053**Diagnostic text:**
10054
10055+--------------------------------------------------------------------------------------------------------------------------------------------------------+
10056|:warning:`warning:` |nbsp| :diagtext:`ignoring '-mcompact-branches=' option because the '`:placeholder:`A`:diagtext:`' architecture does not support it`|
10057+--------------------------------------------------------------------------------------------------------------------------------------------------------+
10058
10059
10060-Wunsupported-dll-base-class-template
10061-------------------------------------
10062**Diagnostic text:**
10063
10064+---------------------------------------------------------------------------+------------------------------------+------------------------------------------------------------------------------+
10065|:warning:`warning:` |nbsp| :diagtext:`propagating dll attribute to` |nbsp| |+----------------------------------+| |nbsp| :diagtext:`base class template without dll attribute is not supported`|
10066| ||:diagtext:`already instantiated` || |
10067| |+----------------------------------+| |
10068| ||:diagtext:`explicitly specialized`|| |
10069| |+----------------------------------+| |
10070+---------------------------------------------------------------------------+------------------------------------+------------------------------------------------------------------------------+
10071
10072
10073-Wunsupported-friend
10074--------------------
10075This diagnostic is enabled by default.
10076
10077**Diagnostic text:**
10078
10079+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10080|:warning:`warning:` |nbsp| :diagtext:`dependent nested name specifier '`:placeholder:`A`:diagtext:`' for friend template declaration is not supported; ignoring this friend declaration`|
10081+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10082
10083+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10084|:warning:`warning:` |nbsp| :diagtext:`dependent nested name specifier '`:placeholder:`A`:diagtext:`' for friend class declaration is not supported; turning off access control for` |nbsp| :placeholder:`B`|
10085+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10086
10087
10088-Wunsupported-nan
10089-----------------
10090This diagnostic is enabled by default.
10091
10092**Diagnostic text:**
10093
10094+-----------------------------------------------------------------------------------------------------------------------------------------------+
10095|:warning:`warning:` |nbsp| :diagtext:`ignoring '-mnan=2008' option because the '`:placeholder:`A`:diagtext:`' architecture does not support it`|
10096+-----------------------------------------------------------------------------------------------------------------------------------------------+
10097
10098+-------------------------------------------------------------------------------------------------------------------------------------------------+
10099|:warning:`warning:` |nbsp| :diagtext:`ignoring '-mnan=legacy' option because the '`:placeholder:`A`:diagtext:`' architecture does not support it`|
10100+-------------------------------------------------------------------------------------------------------------------------------------------------+
10101
10102
10103-Wunsupported-visibility
10104------------------------
10105This diagnostic is enabled by default.
10106
10107**Diagnostic text:**
10108
10109+------------------------------------------------------------------------------------------------------+
10110|:warning:`warning:` |nbsp| :diagtext:`target does not support 'protected' visibility; using 'default'`|
10111+------------------------------------------------------------------------------------------------------+
10112
10113
10114-Wunused
10115--------
10116Some of the diagnostics controlled by this flag are enabled by default.
10117
10118Controls `-Wunused-argument`_, `-Wunused-function`_, `-Wunused-label`_, `-Wunused-private-field`_, `-Wunused-local-typedef`_, `-Wunused-value`_, `-Wunused-variable`_, `-Wunused-property-ivar`_.
10119
10120
10121-Wunused-argument
10122-----------------
10123This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
10124
10125-Wunused-command-line-argument
10126------------------------------
10127This diagnostic is enabled by default.
10128
10129**Diagnostic text:**
10130
10131+---------------------------------------------------------------------------------------------------------------+
10132|:warning:`warning:` |nbsp| :diagtext:`joined argument expects additional value: '`:placeholder:`A`:diagtext:`'`|
10133+---------------------------------------------------------------------------------------------------------------+
10134
Richard Smithce9d5862016-09-14 01:51:10 +000010135+-----------------------------------------------------------------------------------------------------------------------------+
10136|:warning:`warning:` |nbsp| :diagtext:`argument '-fdiagnostics-show-hotness' requires profile-guided optimization information`|
10137+-----------------------------------------------------------------------------------------------------------------------------+
10138
Richard Smithb6a3b4b2016-09-12 05:58:29 +000010139+----------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+
10140|:warning:`warning:` |nbsp| :placeholder:`A`:diagtext:`: '`:placeholder:`B`:diagtext:`' input unused`|+--------------------------------------------------------------------+|
10141| ||+------------------------------------------------------------------+||
10142| ||| |nbsp| :diagtext:`when '`:placeholder:`D`:diagtext:`' is present`|||
10143| ||+------------------------------------------------------------------+||
10144| |+--------------------------------------------------------------------+|
10145| || ||
10146| |+--------------------------------------------------------------------+|
10147+----------------------------------------------------------------------------------------------------+----------------------------------------------------------------------+
10148
10149+----------------------------------------------------------------------------------------------------------------+
10150|:warning:`warning:` |nbsp| :placeholder:`A`:diagtext:`: '`:placeholder:`B`:diagtext:`' input unused in cpp mode`|
10151+----------------------------------------------------------------------------------------------------------------+
10152
10153+--------------------------------------------------------------------------------------+-----------------------------------------------------------------------------+
10154|:warning:`warning:` |nbsp| :placeholder:`A`:diagtext:`: previously preprocessed input`|+---------------------------------------------------------------------------+|
10155| ||+-------------------------------------------------------------------------+||
10156| ||| |nbsp| :diagtext:`unused when '`:placeholder:`C`:diagtext:`' is present`|||
10157| ||+-------------------------------------------------------------------------+||
10158| |+---------------------------------------------------------------------------+|
10159| || ||
10160| |+---------------------------------------------------------------------------+|
10161+--------------------------------------------------------------------------------------+-----------------------------------------------------------------------------+
10162
10163+---------------------------------------------------------------------------------------------------------+
10164|:warning:`warning:` |nbsp| :diagtext:`argument unused during compilation: '`:placeholder:`A`:diagtext:`'`|
10165+---------------------------------------------------------------------------------------------------------+
10166
10167
10168-Wunused-comparison
10169-------------------
10170This diagnostic is enabled by default.
10171
10172**Diagnostic text:**
10173
10174+---------------------------+-----------------------------------------+--------------------------------------------+
10175|:warning:`warning:` |nbsp| |+---------------------------------------+| |nbsp| :diagtext:`comparison result unused`|
10176| ||+----------------+--------------------+|| |
10177| |||+--------------+|:diagtext:`equality`||| |
10178| |||| || ||| |
10179| |||+--------------+| ||| |
10180| ||||:diagtext:`in`|| ||| |
10181| |||+--------------+| ||| |
10182| ||+----------------+--------------------+|| |
10183| |+---------------------------------------+| |
10184| ||:diagtext:`relational` || |
10185| |+---------------------------------------+| |
10186+---------------------------+-----------------------------------------+--------------------------------------------+
10187
10188
10189-Wunused-const-variable
10190-----------------------
10191**Diagnostic text:**
10192
10193+------------------------------------------------------------------------------+
10194|:warning:`warning:` |nbsp| :diagtext:`unused variable` |nbsp| :placeholder:`A`|
10195+------------------------------------------------------------------------------+
10196
10197
10198-Wunused-exception-parameter
10199----------------------------
10200**Diagnostic text:**
10201
10202+-----------------------------------------------------------------------------------------+
10203|:warning:`warning:` |nbsp| :diagtext:`unused exception parameter` |nbsp| :placeholder:`A`|
10204+-----------------------------------------------------------------------------------------+
10205
10206
10207-Wunused-function
10208-----------------
10209Also controls `-Wunneeded-internal-declaration`_.
10210
10211**Diagnostic text:**
10212
10213+------------------------------------------------------------------------------+
10214|:warning:`warning:` |nbsp| :diagtext:`unused function` |nbsp| :placeholder:`A`|
10215+------------------------------------------------------------------------------+
10216
10217
10218-Wunused-getter-return-value
10219----------------------------
10220This diagnostic is enabled by default.
10221
10222**Diagnostic text:**
10223
10224+------------------------------------------------------------------------------------------------------------------+
10225|:warning:`warning:` |nbsp| :diagtext:`property access result unused - getters should not be used for side effects`|
10226+------------------------------------------------------------------------------------------------------------------+
10227
10228
10229-Wunused-label
10230--------------
10231**Diagnostic text:**
10232
10233+---------------------------------------------------------------------------+
10234|:warning:`warning:` |nbsp| :diagtext:`unused label` |nbsp| :placeholder:`A`|
10235+---------------------------------------------------------------------------+
10236
10237
10238-Wunused-local-typedef
10239----------------------
10240**Diagnostic text:**
10241
10242+-----------------------------------------------------+------------------------+------------------------+
10243|:warning:`warning:` |nbsp| :diagtext:`unused` |nbsp| |+----------------------+| |nbsp| :placeholder:`B`|
10244| ||:diagtext:`typedef` || |
10245| |+----------------------+| |
10246| ||:diagtext:`type alias`|| |
10247| |+----------------------+| |
10248+-----------------------------------------------------+------------------------+------------------------+
10249
10250
10251-Wunused-local-typedefs
10252-----------------------
10253Synonym for `-Wunused-local-typedef`_.
10254
10255
10256-Wunused-macros
10257---------------
10258**Diagnostic text:**
10259
10260+--------------------------------------------------------+
10261|:warning:`warning:` |nbsp| :diagtext:`macro is not used`|
10262+--------------------------------------------------------+
10263
10264
10265-Wunused-member-function
10266------------------------
10267Also controls `-Wunneeded-member-function`_.
10268
10269**Diagnostic text:**
10270
10271+-------------------------------------------------------------------------------------+
10272|:warning:`warning:` |nbsp| :diagtext:`unused member function` |nbsp| :placeholder:`A`|
10273+-------------------------------------------------------------------------------------+
10274
10275
10276-Wunused-parameter
10277------------------
10278**Diagnostic text:**
10279
10280+-------------------------------------------------------------------------------+
10281|:warning:`warning:` |nbsp| :diagtext:`unused parameter` |nbsp| :placeholder:`A`|
10282+-------------------------------------------------------------------------------+
10283
10284
10285-Wunused-private-field
10286----------------------
10287**Diagnostic text:**
10288
10289+-----------------------------------------------------------------------------------------------------------+
10290|:warning:`warning:` |nbsp| :diagtext:`private field` |nbsp| :placeholder:`A` |nbsp| :diagtext:`is not used`|
10291+-----------------------------------------------------------------------------------------------------------+
10292
10293
10294-Wunused-property-ivar
10295----------------------
10296**Diagnostic text:**
10297
10298+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
10299|:warning:`warning:` |nbsp| :diagtext:`ivar` |nbsp| :placeholder:`A` |nbsp| :diagtext:`which backs the property is not referenced in this property's accessor`|
10300+-------------------------------------------------------------------------------------------------------------------------------------------------------------+
10301
10302
10303-Wunused-result
10304---------------
10305This diagnostic is enabled by default.
10306
10307**Diagnostic text:**
10308
10309+-------------------------------------------------------------------------------------------------------------------------------------------+
10310|:warning:`warning:` |nbsp| :diagtext:`ignoring return value of function declared with` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute`|
10311+-------------------------------------------------------------------------------------------------------------------------------------------+
10312
10313
10314-Wunused-value
10315--------------
10316This diagnostic is enabled by default.
10317
10318Also controls `-Wunused-comparison`_, `-Wunused-result`_, `-Wunevaluated-expression`_.
10319
10320**Diagnostic text:**
10321
10322+-------------------------------------------------------------------------------------------------------------------------------------------+
10323|:warning:`warning:` |nbsp| :diagtext:`ignoring return value of function declared with` |nbsp| :placeholder:`A` |nbsp| :diagtext:`attribute`|
10324+-------------------------------------------------------------------------------------------------------------------------------------------+
10325
10326+----------------------------------------------------------------------------------------------------------------------------+
10327|:warning:`warning:` |nbsp| :diagtext:`container access result unused - container access should not be used for side effects`|
10328+----------------------------------------------------------------------------------------------------------------------------+
10329
10330+---------------------------------------------------------------+
10331|:warning:`warning:` |nbsp| :diagtext:`expression result unused`|
10332+---------------------------------------------------------------+
10333
10334+-----------------------------------------------------------------------------------------------+
10335|:warning:`warning:` |nbsp| :diagtext:`expression result unused; should this cast be to 'void'?`|
10336+-----------------------------------------------------------------------------------------------+
10337
10338
10339-Wunused-variable
10340-----------------
10341Also controls `-Wunused-const-variable`_.
10342
10343**Diagnostic text:**
10344
10345+------------------------------------------------------------------------------+
10346|:warning:`warning:` |nbsp| :diagtext:`unused variable` |nbsp| :placeholder:`A`|
10347+------------------------------------------------------------------------------+
10348
10349
10350-Wunused-volatile-lvalue
10351------------------------
10352This diagnostic is enabled by default.
10353
10354**Diagnostic text:**
10355
10356+----------------------------------------------------------------------------------------------------------------+
10357|:warning:`warning:` |nbsp| :diagtext:`expression result unused; assign into a variable to force a volatile load`|
10358+----------------------------------------------------------------------------------------------------------------+
10359
10360
10361-Wused-but-marked-unused
10362------------------------
10363**Diagnostic text:**
10364
10365+---------------------------------------------------------------------------------------------+
10366|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`was marked unused but was used`|
10367+---------------------------------------------------------------------------------------------+
10368
10369
10370-Wuser-defined-literals
10371-----------------------
10372This diagnostic is enabled by default.
10373
10374**Diagnostic text:**
10375
10376+--------------------------------------------------------------------------------------------------------+----------------------------------------------------+
10377|:warning:`warning:` |nbsp| :diagtext:`user-defined literal suffixes not starting with '\_' are reserved`|+--------------------------------------------------+|
10378| ||:diagtext:`; no literal will invoke this operator`||
10379| |+--------------------------------------------------+|
10380| || ||
10381| |+--------------------------------------------------+|
10382+--------------------------------------------------------------------------------------------------------+----------------------------------------------------+
10383
10384
10385-Wvarargs
10386---------
10387This diagnostic is enabled by default.
10388
10389**Diagnostic text:**
10390
10391+-----------------------------------------------------------------------------------------------------+
10392|:warning:`warning:` |nbsp| :diagtext:`second argument to 'va\_start' is not the last named parameter`|
10393+-----------------------------------------------------------------------------------------------------+
10394
10395+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10396|:warning:`warning:` |nbsp| :diagtext:`second argument to 'va\_arg' is of promotable type` |nbsp| :placeholder:`A`:diagtext:`; this va\_arg has undefined behavior because arguments will be promoted to` |nbsp| :placeholder:`B`|
10397+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10398
10399+------------------------------------------------------+-----------------------------------------------------------------+---------------------------------------------------------+
10400|:warning:`warning:` |nbsp| :diagtext:`passing` |nbsp| |+---------------------------------------------------------------+| |nbsp| :diagtext:`to 'va\_start' has undefined behavior`|
10401| ||:diagtext:`an object that undergoes default argument promotion`|| |
10402| |+---------------------------------------------------------------+| |
10403| ||:diagtext:`an object of reference type` || |
10404| |+---------------------------------------------------------------+| |
10405| ||:diagtext:`a parameter declared with the 'register' keyword` || |
10406| |+---------------------------------------------------------------+| |
10407+------------------------------------------------------+-----------------------------------------------------------------+---------------------------------------------------------+
10408
10409
10410-Wvariadic-macros
10411-----------------
10412**Diagnostic text:**
10413
10414+--------------------------------------------------------------------------------+
10415|:warning:`warning:` |nbsp| :diagtext:`named variadic macros are a GNU extension`|
10416+--------------------------------------------------------------------------------+
10417
10418+------------------------------------------------------------------------+
10419|:warning:`warning:` |nbsp| :diagtext:`variadic macros are a C99 feature`|
10420+------------------------------------------------------------------------+
10421
10422
10423-Wvector-conversion
10424-------------------
10425**Diagnostic text:**
10426
10427+------------------------------------------------------------------------+----------------------------------------------------------------+
10428|:warning:`warning:` |nbsp| :diagtext:`incompatible vector types` |nbsp| |+--------------------------------------------------------------+|
10429| ||:diagtext:`assigning to different types` ||
10430| |+--------------------------------------------------------------+|
10431| ||:diagtext:`passing to parameter of different type` ||
10432| |+--------------------------------------------------------------+|
10433| ||:diagtext:`returning from function with different return type`||
10434| |+--------------------------------------------------------------+|
10435| ||:diagtext:`converting between types` ||
10436| |+--------------------------------------------------------------+|
10437| ||:diagtext:`initializing with expression of different type` ||
10438| |+--------------------------------------------------------------+|
10439| ||:diagtext:`sending to parameter of different type` ||
10440| |+--------------------------------------------------------------+|
10441| ||:diagtext:`casting between types` ||
10442| |+--------------------------------------------------------------+|
10443+------------------------------------------------------------------------+----------------------------------------------------------------+
10444
10445
10446-Wvector-conversions
10447--------------------
10448Synonym for `-Wvector-conversion`_.
10449
10450
10451-Wvexing-parse
10452--------------
10453This diagnostic is enabled by default.
10454
10455**Diagnostic text:**
10456
10457+----------------------------------------------------------------------------------------------+
10458|:warning:`warning:` |nbsp| :diagtext:`empty parentheses interpreted as a function declaration`|
10459+----------------------------------------------------------------------------------------------+
10460
10461+-----------------------------------------------------------------------------------------------+
10462|:warning:`warning:` |nbsp| :diagtext:`parentheses were disambiguated as a function declaration`|
10463+-----------------------------------------------------------------------------------------------+
10464
10465
10466-Wvisibility
10467------------
10468This diagnostic is enabled by default.
10469
10470**Diagnostic text:**
10471
10472+---------------------------------------------------------------------------------------------------------------------------------------------+
10473|:warning:`warning:` |nbsp| :diagtext:`declaration of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will not be visible outside of this function`|
10474+---------------------------------------------------------------------------------------------------------------------------------------------+
10475
10476+----------------------------------------------------------------------------------------------------------------------------------------------+
10477|:warning:`warning:` |nbsp| :diagtext:`redefinition of` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will not be visible outside of this function`|
10478+----------------------------------------------------------------------------------------------------------------------------------------------+
10479
10480
10481-Wvla
10482-----
10483**Diagnostic text:**
10484
10485+-----------------------------------------------------------------+
10486|:warning:`warning:` |nbsp| :diagtext:`variable length array used`|
10487+-----------------------------------------------------------------+
10488
10489
10490-Wvla-extension
10491---------------
10492**Diagnostic text:**
10493
10494+-------------------------------------------------------------------------------+
10495|:warning:`warning:` |nbsp| :diagtext:`variable length arrays are a C99 feature`|
10496+-------------------------------------------------------------------------------+
10497
10498
10499-Wvoid-ptr-dereference
10500----------------------
10501This diagnostic is enabled by default.
10502
10503**Diagnostic text:**
10504
10505+--------------------------------------------------------------------------------------------------------------------+
10506|:warning:`warning:` |nbsp| :diagtext:`ISO C++ does not allow indirection on operand of type` |nbsp| :placeholder:`A`|
10507+--------------------------------------------------------------------------------------------------------------------+
10508
10509
10510-Wvolatile-register-var
10511-----------------------
10512This diagnostic flag exists for GCC compatibility, and has no effect in Clang.
10513
10514-Wweak-template-vtables
10515-----------------------
10516**Diagnostic text:**
10517
10518+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
10519|:warning:`warning:` |nbsp| :diagtext:`explicit template instantiation` |nbsp| :placeholder:`A` |nbsp| :diagtext:`will emit a vtable in every translation unit`|
10520+--------------------------------------------------------------------------------------------------------------------------------------------------------------+
10521
10522
10523-Wweak-vtables
10524--------------
10525**Diagnostic text:**
10526
10527+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10528|:warning:`warning:` |nbsp| :placeholder:`A` |nbsp| :diagtext:`has no out-of-line virtual method definitions; its vtable will be emitted in every translation unit`|
10529+------------------------------------------------------------------------------------------------------------------------------------------------------------------+
10530
10531
10532-Wwritable-strings
10533------------------
10534This diagnostic is enabled by default.
10535
10536Also controls `-Wdeprecated-writable-strings`_.
10537
10538**Diagnostic text:**
10539
10540+-------------------------------------------------------------------------------------------------------------------------+
10541|:warning:`warning:` |nbsp| :diagtext:`ISO C++11 does not allow conversion from string literal to` |nbsp| :placeholder:`A`|
10542+-------------------------------------------------------------------------------------------------------------------------+
10543
10544
10545-Wwrite-strings
10546---------------
10547Synonym for `-Wwritable-strings`_.
10548
10549
10550-Wzero-length-array
10551-------------------
10552**Diagnostic text:**
10553
10554+------------------------------------------------------------------------+
10555|:warning:`warning:` |nbsp| :diagtext:`zero size arrays are an extension`|
10556+------------------------------------------------------------------------+
10557
10558