]>
Commit | Line | Data |
---|---|---|
fef3106c | 1 | ; Options for the C, ObjC, C++ and ObjC++ front ends. |
a5544970 | 2 | ; Copyright (C) 2003-2019 Free Software Foundation, Inc. |
fef3106c NB |
3 | ; |
4 | ; This file is part of GCC. | |
5 | ; | |
6 | ; GCC is free software; you can redistribute it and/or modify it under | |
7 | ; the terms of the GNU General Public License as published by the Free | |
9dcd6f09 | 8 | ; Software Foundation; either version 3, or (at your option) any later |
fef3106c | 9 | ; version. |
c22cacf3 | 10 | ; |
fef3106c NB |
11 | ; GCC is distributed in the hope that it will be useful, but WITHOUT ANY |
12 | ; WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
13 | ; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
14 | ; for more details. | |
c22cacf3 | 15 | ; |
fef3106c | 16 | ; You should have received a copy of the GNU General Public License |
9dcd6f09 NC |
17 | ; along with GCC; see the file COPYING3. If not see |
18 | ; <http://www.gnu.org/licenses/>. | |
fef3106c | 19 | |
8abb6b22 | 20 | ; See the GCC internals manual for a description of this file's format. |
fef3106c | 21 | |
fef3106c NB |
22 | ; Please try to keep this file in ASCII collating order. |
23 | ||
be43ab4e NB |
24 | Language |
25 | C | |
26 | ||
27 | Language | |
28 | ObjC | |
29 | ||
30 | Language | |
31 | C++ | |
32 | ||
33 | Language | |
34 | ObjC++ | |
35 | ||
e200444e JM |
36 | -all-warnings |
37 | C ObjC C++ ObjC++ Warning Alias(Wall) | |
38 | ||
39 | -ansi | |
40 | C ObjC C++ ObjC++ Alias(ansi) | |
41 | ||
42 | -assert | |
43 | C ObjC C++ ObjC++ Separate Alias(A) MissingArgError(assertion missing after %qs) | |
44 | ||
45 | -assert= | |
46 | C ObjC C++ ObjC++ Joined Alias(A) MissingArgError(assertion missing after %qs) | |
47 | ||
48 | -comments | |
49 | C ObjC C++ ObjC++ Alias(C) | |
50 | ||
51 | -comments-in-macros | |
52 | C ObjC C++ ObjC++ Alias(CC) | |
53 | ||
54 | -define-macro | |
55 | C ObjC C++ ObjC++ Separate Alias(D) MissingArgError(macro name missing after %qs) | |
56 | ||
57 | -define-macro= | |
58 | C ObjC C++ ObjC++ Joined Alias(D) MissingArgError(macro name missing after %qs) | |
59 | ||
60 | -dependencies | |
61 | C ObjC C++ ObjC++ Alias(M) | |
62 | ||
63 | -dump | |
64 | C ObjC C++ ObjC++ Separate Alias(d) | |
65 | ||
66 | -dump= | |
67 | C ObjC C++ ObjC++ Joined Alias(d) | |
68 | ||
69 | -imacros | |
70 | C ObjC C++ ObjC++ Separate Alias(imacros) MissingArgError(missing filename after %qs) | |
71 | ||
72 | -imacros= | |
73 | C ObjC C++ ObjC++ Joined Alias(imacros) MissingArgError(missing filename after %qs) | |
74 | ||
75 | -include | |
76 | C ObjC C++ ObjC++ Separate Alias(include) MissingArgError(missing filename after %qs) | |
77 | ||
78 | -include= | |
79 | C ObjC C++ ObjC++ Joined Alias(include) MissingArgError(missing filename after %qs) | |
80 | ||
81 | -include-barrier | |
82 | C ObjC C++ ObjC++ Alias(I, -) | |
83 | ||
84 | -include-directory | |
85 | C ObjC C++ ObjC++ Separate Alias(I) MissingArgError(missing path after %qs) | |
86 | ||
87 | -include-directory= | |
88 | C ObjC C++ ObjC++ Joined Alias(I) MissingArgError(missing path after %qs) | |
89 | ||
90 | -include-directory-after | |
91 | C ObjC C++ ObjC++ Separate Alias(idirafter) MissingArgError(missing path after %qs) | |
92 | ||
93 | -include-directory-after= | |
94 | C ObjC C++ ObjC++ Joined Alias(idirafter) MissingArgError(missing path after %qs) | |
95 | ||
96 | -include-prefix | |
97 | C ObjC C++ ObjC++ Separate Alias(iprefix) | |
98 | ||
99 | -include-prefix= | |
100 | C ObjC C++ ObjC++ JoinedOrMissing Alias(iprefix) | |
101 | ||
102 | -include-with-prefix | |
103 | C ObjC C++ ObjC++ Separate Alias(iwithprefix) | |
104 | ||
105 | -include-with-prefix= | |
106 | C ObjC C++ ObjC++ JoinedOrMissing Alias(iwithprefix) | |
107 | ||
108 | -include-with-prefix-after | |
109 | C ObjC C++ ObjC++ Separate Alias(iwithprefix) | |
110 | ||
111 | -include-with-prefix-after= | |
112 | C ObjC C++ ObjC++ JoinedOrMissing Alias(iwithprefix) | |
113 | ||
114 | -include-with-prefix-before | |
115 | C ObjC C++ ObjC++ Separate Alias(iwithprefixbefore) | |
116 | ||
117 | -include-with-prefix-before= | |
118 | C ObjC C++ ObjC++ JoinedOrMissing Alias(iwithprefixbefore) | |
119 | ||
120 | -no-integrated-cpp | |
121 | Driver Alias(no-integrated-cpp) | |
122 | ||
123 | -no-line-commands | |
124 | C ObjC C++ ObjC++ Alias(P) | |
125 | ||
126 | -no-standard-includes | |
127 | C ObjC C++ ObjC++ Alias(nostdinc) | |
128 | ||
129 | -no-warnings | |
130 | C ObjC C++ ObjC++ Alias(w) | |
131 | ||
132 | -output | |
133 | C ObjC C++ ObjC++ Separate Alias(o) | |
134 | ||
135 | -output= | |
136 | C ObjC C++ ObjC++ Joined Alias(o) | |
137 | ||
fef3106c NB |
138 | -output-pch= |
139 | C ObjC C++ ObjC++ Joined Separate | |
140 | ||
e200444e JM |
141 | -pedantic |
142 | C ObjC C++ ObjC++ Alias(pedantic) | |
143 | ||
e200444e JM |
144 | -preprocess |
145 | C ObjC C++ ObjC++ Undocumented Alias(E) | |
146 | ||
147 | -print-missing-file-dependencies | |
148 | C ObjC C++ ObjC++ Alias(MG) | |
149 | ||
150 | -trace-includes | |
151 | C ObjC C++ ObjC++ Alias(H) | |
152 | ||
153 | -traditional | |
154 | Driver Alias(traditional) | |
155 | ||
156 | -traditional-cpp | |
157 | C ObjC C++ ObjC++ Alias(traditional-cpp) | |
158 | ||
159 | -trigraphs | |
160 | C ObjC C++ ObjC++ Alias(trigraphs) | |
161 | ||
162 | -undefine-macro | |
163 | C ObjC C++ ObjC++ Separate Alias(U) MissingArgError(macro name missing after %qs) | |
164 | ||
165 | -undefine-macro= | |
166 | C ObjC C++ ObjC++ Joined Alias(U) MissingArgError(macro name missing after %qs) | |
167 | ||
168 | -user-dependencies | |
169 | C ObjC C++ ObjC++ Alias(MM) | |
170 | ||
171 | -verbose | |
172 | Common C ObjC C++ ObjC++ Alias(v) | |
173 | ||
174 | -write-dependencies | |
175 | C ObjC C++ ObjC++ NoDriverArg Separate Alias(MD) MissingArgError(missing filename after %qs) | |
176 | ||
177 | -write-user-dependencies | |
178 | C ObjC C++ ObjC++ NoDriverArg Separate Alias(MMD) MissingArgError(missing filename after %qs) | |
179 | ||
fef3106c | 180 | A |
61ff2bdc | 181 | C ObjC C++ ObjC++ Joined Separate MissingArgError(assertion missing after %qs) |
a7b2e184 | 182 | -A<question>=<answer> Assert the <answer> to <question>. Putting '-' before <question> disables the <answer> to <question>. |
fef3106c NB |
183 | |
184 | C | |
185 | C ObjC C++ ObjC++ | |
a7b2e184 | 186 | Do not discard comments. |
fef3106c NB |
187 | |
188 | CC | |
189 | C ObjC C++ ObjC++ | |
a7b2e184 | 190 | Do not discard comments in macro expansions. |
fef3106c NB |
191 | |
192 | D | |
61ff2bdc | 193 | C ObjC C++ ObjC++ Joined Separate MissingArgError(macro name missing after %qs) |
a7b2e184 | 194 | -D<macro>[=<val>] Define a <macro> with <val> as its value. If just <macro> is given, <val> is taken to be 1. |
fef3106c NB |
195 | |
196 | E | |
5498f011 | 197 | C ObjC C++ ObjC++ Undocumented Var(flag_preprocess_only) |
fef3106c | 198 | |
94d1613b | 199 | F |
bd837408 | 200 | Driver C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 201 | -F <dir> Add <dir> to the end of the main framework include path. |
94d1613b | 202 | |
1ee62b92 PG |
203 | fgimple |
204 | C Var(flag_gimple) Init(0) | |
205 | Enable parsing GIMPLE. | |
206 | ||
fef3106c NB |
207 | H |
208 | C ObjC C++ ObjC++ | |
a7b2e184 | 209 | Print the name of header files as they are used. |
fef3106c NB |
210 | |
211 | I | |
61ff2bdc | 212 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 213 | -I <dir> Add <dir> to the end of the main include path. |
fef3106c NB |
214 | |
215 | M | |
216 | C ObjC C++ ObjC++ | |
a7b2e184 | 217 | Generate make dependencies. |
fef3106c | 218 | |
c878765b JM |
219 | MD |
220 | C ObjC C++ ObjC++ NoDriverArg Separate MissingArgError(missing filename after %qs) | |
a7b2e184 | 221 | Generate make dependencies and compile. |
fef3106c NB |
222 | |
223 | MF | |
61ff2bdc | 224 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing filename after %qs) |
a7b2e184 | 225 | -MF <file> Write dependency output to the given file. |
fef3106c NB |
226 | |
227 | MG | |
228 | C ObjC C++ ObjC++ | |
a7b2e184 | 229 | Treat missing header files as generated files. |
fef3106c NB |
230 | |
231 | MM | |
232 | C ObjC C++ ObjC++ | |
a7b2e184 | 233 | Like -M but ignore system header files. |
fef3106c | 234 | |
c878765b JM |
235 | MMD |
236 | C ObjC C++ ObjC++ NoDriverArg Separate MissingArgError(missing filename after %qs) | |
a7b2e184 | 237 | Like -MD but ignore system header files. |
fef3106c NB |
238 | |
239 | MP | |
240 | C ObjC C++ ObjC++ | |
a7b2e184 | 241 | Generate phony targets for all headers. |
fef3106c NB |
242 | |
243 | MQ | |
61ff2bdc | 244 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing makefile target after %qs) |
a7b2e184 | 245 | -MQ <target> Add a MAKE-quoted target. |
fef3106c NB |
246 | |
247 | MT | |
61ff2bdc | 248 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing makefile target after %qs) |
a7b2e184 | 249 | -MT <target> Add an unquoted target. |
fef3106c NB |
250 | |
251 | P | |
252 | C ObjC C++ ObjC++ | |
a7b2e184 | 253 | Do not generate #line directives. |
fef3106c NB |
254 | |
255 | U | |
61ff2bdc | 256 | C ObjC C++ ObjC++ Joined Separate MissingArgError(macro name missing after %qs) |
a7b2e184 | 257 | -U<macro> Undefine <macro>. |
fef3106c NB |
258 | |
259 | Wabi | |
d7f09764 | 260 | C ObjC C++ ObjC++ LTO Var(warn_abi) Warning |
a7b2e184 | 261 | Warn about things that will change when compiling with an ABI-compliant compiler. |
fef3106c | 262 | |
62984918 JM |
263 | Wabi= |
264 | C ObjC C++ ObjC++ LTO Joined RejectNegative UInteger Warning | |
a7b2e184 | 265 | Warn about things that change between the current -fabi-version and the specified version. |
62984918 | 266 | |
7dbb85a7 JM |
267 | Wabi-tag |
268 | C++ ObjC++ Var(warn_abi_tag) Warning | |
a7b2e184 | 269 | Warn if a subobject has an abi_tag attribute that the complete object type does not have. |
7dbb85a7 | 270 | |
bce08d50 | 271 | Wpsabi |
50b15873 | 272 | C ObjC C++ ObjC++ LTO Var(warn_psabi) Init(1) Warning Undocumented LangEnabledBy(C ObjC C++ ObjC++,Wabi) |
bce08d50 | 273 | |
80c6d1f4 MJ |
274 | Wabsolute-value |
275 | C ObjC Var(warn_absolute_value) Warning EnabledBy(Wextra) | |
276 | Warn on suspicious calls of standard functions computing absolute values. | |
277 | ||
c116cd05 | 278 | Waddress |
4a0ae68e | 279 | C ObjC C++ ObjC++ Var(warn_address) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 280 | Warn about suspicious uses of memory addresses. |
c116cd05 | 281 | |
af63ba4b JM |
282 | Enum |
283 | Name(warn_aligned_new_level) Type(int) UnknownError(argument %qs to %<-Waligned-new%> not recognized) | |
284 | ||
285 | EnumValue | |
286 | Enum(warn_aligned_new_level) String(none) Value(0) | |
287 | ||
288 | EnumValue | |
289 | Enum(warn_aligned_new_level) String(global) Value(1) | |
290 | ||
291 | EnumValue | |
292 | Enum(warn_aligned_new_level) String(all) Value(2) | |
293 | ||
294 | Waligned-new | |
295 | C++ ObjC++ Alias(Waligned-new=,global,none) | |
296 | Warn about 'new' of type with extended alignment without -faligned-new. | |
297 | ||
298 | Waligned-new= | |
2e1c20b1 | 299 | C++ ObjC++ Var(warn_aligned_new) Enum(warn_aligned_new_level) Joined RejectNegative Warning LangEnabledBy(C++ ObjC++,Wall,1,0) |
6a825afe | 300 | -Waligned-new=[none|global|all] Warn even if 'new' uses a class member allocation function. |
af63ba4b | 301 | |
fef3106c | 302 | Wall |
c662432e | 303 | C ObjC C++ ObjC++ Warning |
a7b2e184 | 304 | Enable most warning messages. |
fef3106c | 305 | |
adc577c5 AH |
306 | Walloca |
307 | C ObjC C++ ObjC++ Var(warn_alloca) Warning | |
308 | Warn on any use of alloca. | |
309 | ||
8bd9f164 | 310 | Walloc-size-larger-than= |
00abf86c | 311 | C ObjC C++ LTO ObjC++ Var(warn_alloc_size_limit) Joined Host_Wide_Int ByteSize Warning Init(HOST_WIDE_INT_MAX) |
8bd9f164 MS |
312 | -Walloc-size-larger-than=<bytes> Warn for calls to allocation functions that |
313 | attempt to allocate objects larger than the specified number of bytes. | |
314 | ||
d258f4aa | 315 | Wno-alloc-size-larger-than |
00abf86c | 316 | C ObjC C++ LTO ObjC++ Alias(Walloc-size-larger-than=,18446744073709551615EiB,none) Warning |
d258f4aa MS |
317 | -Wno-alloc-size-larger-than Disable Walloc-size-larger-than= warning. Equivalent to Walloc-size-larger-than=<SIZE_MAX> or larger. |
318 | ||
8bd9f164 MS |
319 | Walloc-zero |
320 | C ObjC C++ ObjC++ Var(warn_alloc_zero) Warning | |
321 | -Walloc-zero Warn for calls to allocation functions that specify zero bytes. | |
322 | ||
adc577c5 | 323 | Walloca-larger-than= |
00abf86c | 324 | C ObjC C++ LTO ObjC++ Var(warn_alloca_limit) Warning Joined Host_Wide_Int ByteSize Init(HOST_WIDE_INT_MAX) |
9453ba0a | 325 | -Walloca-larger-than=<number> Warn on unbounded uses of |
adc577c5 AH |
326 | alloca, and on bounded uses of alloca whose bound can be larger than |
327 | <number> bytes. | |
328 | ||
00abf86c MS |
329 | Wno-alloca-larger-than |
330 | C ObjC C++ LTO ObjC++ Alias(Walloca-larger-than=,18446744073709551615EiB,none) Warning | |
331 | -Wno-alloca-larger-than Disable Walloca-larger-than= warning. Equivalent to Walloca-larger-than=<SIZE_MAX> or larger. | |
332 | ||
34a180a6 | 333 | Warray-bounds |
0d7f9065 | 334 | LangEnabledBy(C ObjC C++ LTO ObjC++) |
34a180a6 MLI |
335 | ; in common.opt |
336 | ||
de1b5c17 | 337 | Warray-bounds= |
cea71f0a | 338 | LangEnabledBy(C ObjC C++ LTO ObjC++,Wall,1,0) |
de1b5c17 MU |
339 | ; in common.opt |
340 | ||
6e955430 | 341 | Wassign-intercept |
c662432e | 342 | ObjC ObjC++ Var(warn_assign_intercept) Warning |
a7b2e184 | 343 | Warn whenever an Objective-C assignment is being intercepted by the garbage collector. |
6e955430 | 344 | |
fef3106c | 345 | Wbad-function-cast |
c662432e | 346 | C ObjC Var(warn_bad_function_cast) Warning |
a7b2e184 | 347 | Warn about casting functions to incompatible types. |
fef3106c | 348 | |
04159acf MP |
349 | Wbool-compare |
350 | C ObjC C++ ObjC++ Var(warn_bool_compare) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 351 | Warn about boolean expression compared with an integer value different from true/false. |
04159acf | 352 | |
9a2300e9 MP |
353 | Wbool-operation |
354 | C ObjC C++ ObjC++ Var(warn_bool_op) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
355 | Warn about certain operations on boolean expressions. | |
356 | ||
8423e57c MS |
357 | Wframe-address |
358 | C ObjC C++ ObjC++ Var(warn_frame_address) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 359 | Warn when __builtin_frame_address or __builtin_return_address is used unsafely. |
8423e57c | 360 | |
48330c93 BE |
361 | Wbuiltin-declaration-mismatch |
362 | C ObjC C++ ObjC++ Var(warn_builtin_declaraion_mismatch) Init(1) Warning | |
363 | Warn when a built-in function is declared with the wrong signature. | |
364 | ||
c047ce93 | 365 | Wbuiltin-macro-redefined |
b559c810 | 366 | C ObjC C++ ObjC++ CPP(warn_builtin_macro_redefined) CppReason(CPP_W_BUILTIN_MACRO_REDEFINED) Var(cpp_warn_builtin_macro_redefined) Init(1) Warning |
a7b2e184 | 367 | Warn when a built-in preprocessor macro is undefined or redefined. |
c047ce93 | 368 | |
9f936c86 JM |
369 | Wc11-c2x-compat |
370 | C ObjC Var(warn_c11_c2x_compat) Init(-1) Warning | |
371 | Warn about features not present in ISO C11, but present in ISO C2X. | |
372 | ||
f3bede71 | 373 | Wc90-c99-compat |
b559c810 | 374 | C ObjC CPP(cpp_warn_c90_c99_compat) CppReason(CPP_W_C90_C99_COMPAT) Var(warn_c90_c99_compat) Init(-1) Warning |
a7b2e184 | 375 | Warn about features not present in ISO C90, but present in ISO C99. |
f3bede71 | 376 | |
35aff4fb MP |
377 | Wc99-c11-compat |
378 | C ObjC Var(warn_c99_c11_compat) Init(-1) Warning | |
a7b2e184 | 379 | Warn about features not present in ISO C99, but present in ISO C11. |
35aff4fb | 380 | |
b7e20b53 | 381 | Wc++-compat |
b559c810 | 382 | C ObjC Var(warn_cxx_compat) CPP(warn_cxx_operator_names) CppReason(CPP_W_CXX_OPERATOR_NAMES) Init(0) Warning |
a7b2e184 | 383 | Warn about C constructs that are not in the common subset of C and C++. |
b7e20b53 | 384 | |
e1f1ee86 | 385 | Wc++0x-compat |
765189ff | 386 | C++ ObjC++ Warning Alias(Wc++11-compat) Undocumented |
97e3ad20 JM |
387 | |
388 | Wc++11-compat | |
765189ff | 389 | C++ ObjC++ Var(warn_cxx11_compat) Warning LangEnabledBy(C++ ObjC++,Wall) Init(0) CPP(cpp_warn_cxx11_compat) CppReason(CPP_W_CXX11_COMPAT) |
a7b2e184 | 390 | Warn about C++ constructs whose meaning differs between ISO C++ 1998 and ISO C++ 2011. |
b7e20b53 | 391 | |
20b06add JM |
392 | Wc++14-compat |
393 | C++ ObjC++ Var(warn_cxx14_compat) Warning LangEnabledBy(C++ ObjC++,Wall) | |
a7b2e184 | 394 | Warn about C++ constructs whose meaning differs between ISO C++ 2011 and ISO C++ 2014. |
20b06add | 395 | |
51dc6603 | 396 | Wc++1z-compat |
7b936140 | 397 | C++ ObjC++ Warning Alias(Wc++17-compat) Undocumented |
51dc6603 JM |
398 | |
399 | Wc++17-compat | |
7b936140 JJ |
400 | C++ ObjC++ Var(warn_cxx17_compat) Warning LangEnabledBy(C++ ObjC++,Wall) |
401 | Warn about C++ constructs whose meaning differs between ISO C++ 2014 and ISO C++ 2017. | |
51dc6603 | 402 | |
c65e18d3 BE |
403 | Wcast-function-type |
404 | C ObjC C++ ObjC++ Var(warn_cast_function_type) Warning EnabledBy(Wextra) | |
405 | Warn about casts between incompatible function types. | |
406 | ||
fef3106c | 407 | Wcast-qual |
c662432e | 408 | C ObjC C++ ObjC++ Var(warn_cast_qual) Warning |
a7b2e184 | 409 | Warn about casts which discard qualifiers. |
fef3106c | 410 | |
3fa4634c VR |
411 | Wcatch-value |
412 | C++ ObjC++ Warning Alias(Wcatch-value=, 1, 0) | |
413 | Warn about catch handlers of non-reference type. | |
414 | ||
63dbcd13 | 415 | Wcatch-value= |
b22dbd03 | 416 | C++ ObjC++ Var(warn_catch_value) Warning Joined RejectNegative UInteger LangEnabledBy(C++ ObjC++,Wall, 1, 0) IntegerRange(0, 3) |
63dbcd13 VR |
417 | Warn about catch handlers of non-reference type. |
418 | ||
fef3106c | 419 | Wchar-subscripts |
4a0ae68e | 420 | C ObjC C++ ObjC++ Var(warn_char_subscripts) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 421 | Warn about subscripts whose type is \"char\". |
fef3106c | 422 | |
d5e254e1 | 423 | Wchkp |
c0c12356 | 424 | C ObjC C++ ObjC++ Warning Deprecated |
31db0fe0 | 425 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 | 426 | |
2b001724 | 427 | Wclobbered |
95744782 | 428 | C ObjC C++ ObjC++ Var(warn_clobbered) Warning EnabledBy(Wextra) |
a7b2e184 | 429 | Warn about variables that might be changed by \"longjmp\" or \"vfork\". |
2b001724 | 430 | |
ab574db6 MP |
431 | Wcomma-subscript |
432 | C++ ObjC++ Var(warn_comma_subscript) Warning | |
433 | Warn about uses of a comma operator within a subscripting expression. | |
434 | ||
fef3106c | 435 | Wcomment |
b559c810 | 436 | C ObjC C++ ObjC++ CPP(warn_comments) CppReason(CPP_W_COMMENTS) Var(cpp_warn_comment) Init(0) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 437 | Warn about possibly nested block comments, and C++ comments spanning more than one physical line. |
fef3106c NB |
438 | |
439 | Wcomments | |
5de8299c | 440 | C ObjC C++ ObjC++ Warning Alias(Wcomment) |
a7b2e184 | 441 | Synonym for -Wcomment. |
fef3106c | 442 | |
dfeadaa0 PC |
443 | Wconditionally-supported |
444 | C++ ObjC++ Var(warn_conditionally_supported) Warning | |
a7b2e184 | 445 | Warn for conditionally-supported constructs. |
dfeadaa0 | 446 | |
fef3106c | 447 | Wconversion |
c662432e | 448 | C ObjC C++ ObjC++ Var(warn_conversion) Warning |
a7b2e184 | 449 | Warn for implicit type conversions that may change a value. |
fef3106c | 450 | |
17251338 MLI |
451 | Wconversion-null |
452 | C++ ObjC++ Var(warn_conversion_null) Init(1) Warning | |
a7b2e184 | 453 | Warn for converting NULL from/to a non-pointer type. |
17251338 | 454 | |
b559c810 MLI |
455 | Wcpp |
456 | C ObjC C++ ObjC++ CppReason(CPP_W_WARNING_DIRECTIVE) | |
457 | ; Documented in common.opt | |
458 | ||
fef3106c | 459 | Wctor-dtor-privacy |
c662432e | 460 | C++ ObjC++ Var(warn_ctor_dtor_privacy) Warning |
a7b2e184 | 461 | Warn when all constructors and destructors are private. |
deef7113 MP |
462 | |
463 | Wdangling-else | |
464 | C ObjC C++ ObjC++ Var(warn_dangling_else) Warning LangEnabledBy(C ObjC C++ ObjC++,Wparentheses) | |
465 | Warn about dangling else. | |
fef3106c | 466 | |
b559c810 MLI |
467 | Wdate-time |
468 | C ObjC C++ ObjC++ CPP(warn_date_time) CppReason(CPP_W_DATE_TIME) Var(cpp_warn_date_time) Init(0) Warning | |
a7b2e184 | 469 | Warn about __TIME__, __DATE__ and __TIMESTAMP__ usage. |
b559c810 | 470 | |
85617eba | 471 | Wdeclaration-after-statement |
177cce46 | 472 | C ObjC Var(warn_declaration_after_statement) Init(-1) Warning |
a7b2e184 | 473 | Warn when a declaration is found after a statement. |
85617eba | 474 | |
c9b0866a PC |
475 | Wdelete-incomplete |
476 | C++ ObjC++ Var(warn_delete_incomplete) Init(1) Warning | |
a7b2e184 | 477 | Warn when deleting a pointer to incomplete type. |
c9b0866a | 478 | |
014ab419 | 479 | Wdelete-non-virtual-dtor |
27e51192 | 480 | C++ ObjC++ Var(warn_delnonvdtor) Warning LangEnabledBy(C++ ObjC++,Wall || Weffc++) |
a7b2e184 | 481 | Warn about deleting polymorphic objects with non-virtual destructors. |
014ab419 | 482 | |
fef3106c | 483 | Wdeprecated |
99063eee RS |
484 | C C++ ObjC ObjC++ CPP(cpp_warn_deprecated) CppReason(CPP_W_DEPRECATED) |
485 | ; Documented in common.opt | |
fef3106c | 486 | |
b46b715d | 487 | Wdeprecated-copy |
5c8b3702 JM |
488 | C++ ObjC++ Var(warn_deprecated_copy) Warning LangEnabledBy(C++ ObjC++, Wextra) |
489 | Mark implicitly-declared copy operations as deprecated if the class has a | |
490 | user-provided copy operation. | |
491 | ||
492 | Wdeprecated-copy-dtor | |
493 | C++ ObjC++ Var(warn_deprecated_copy, 2) Warning | |
b46b715d JM |
494 | Mark implicitly-declared copy operations as deprecated if the class has a |
495 | user-provided copy operation or destructor. | |
496 | ||
976d5a22 TT |
497 | Wdesignated-init |
498 | C ObjC Var(warn_designated_init) Init(1) Warning | |
a7b2e184 | 499 | Warn about positional initialization of structs requiring designated initializers. |
976d5a22 | 500 | |
768952be MU |
501 | Wdiscarded-array-qualifiers |
502 | C ObjC Var(warn_discarded_array_qualifiers) Init(1) Warning | |
a7b2e184 | 503 | Warn if qualifiers on arrays which are pointer targets are discarded. |
768952be | 504 | |
d00887e8 MP |
505 | Wdiscarded-qualifiers |
506 | C ObjC Var(warn_discarded_qualifiers) Init(1) Warning | |
a7b2e184 | 507 | Warn if type qualifiers on pointers are discarded. |
d00887e8 | 508 | |
fef3106c | 509 | Wdiv-by-zero |
2cbac420 | 510 | C ObjC C++ ObjC++ Var(warn_div_by_zero) Init(1) Warning |
a7b2e184 | 511 | Warn about compile-time integer division by zero. |
fef3106c | 512 | |
2ebd93e1 MP |
513 | Wduplicated-branches |
514 | C ObjC C++ ObjC++ Var(warn_duplicated_branches) Init(0) Warning | |
515 | Warn about duplicated branches in if-else statements. | |
516 | ||
3e3b8d63 | 517 | Wduplicated-cond |
12651878 | 518 | C ObjC C++ ObjC++ Var(warn_duplicated_cond) Init(0) Warning |
a7b2e184 | 519 | Warn about duplicated conditions in an if-else-if chain. |
3e3b8d63 | 520 | |
fef3106c | 521 | Weffc++ |
c662432e | 522 | C++ ObjC++ Var(warn_ecpp) Warning |
a7b2e184 | 523 | Warn about violations of Effective C++ style rules. |
fef3106c | 524 | |
b3b433c5 | 525 | Wempty-body |
95744782 | 526 | C ObjC C++ ObjC++ Var(warn_empty_body) Warning EnabledBy(Wextra) |
a7b2e184 | 527 | Warn about an empty body in an if or else statement. |
b3b433c5 | 528 | |
fef3106c | 529 | Wendif-labels |
b559c810 | 530 | C ObjC C++ ObjC++ CPP(warn_endif_labels) CppReason(CPP_W_ENDIF_LABELS) Var(cpp_warn_endif_labels) Init(1) Warning LangEnabledBy(C ObjC C++ ObjC++,Wpedantic) |
f6a7a9d5 | 531 | Warn about stray tokens after #else and #endif. |
fef3106c | 532 | |
a3299096 | 533 | Wenum-compare |
27e51192 | 534 | C ObjC C++ ObjC++ Var(warn_enum_compare) Init(-1) Warning LangEnabledBy(C ObjC,Wall || Wc++-compat) |
a7b2e184 | 535 | Warn about comparison of different enum types. |
a3299096 | 536 | |
fef3106c NB |
537 | Werror |
538 | C ObjC C++ ObjC++ | |
72de27ea | 539 | ; Documented in common.opt |
fef3106c NB |
540 | |
541 | Werror-implicit-function-declaration | |
5de8299c | 542 | C ObjC RejectNegative Warning Alias(Werror=, implicit-function-declaration) |
a7b2e184 | 543 | This switch is deprecated; use -Werror=implicit-function-declaration instead. |
fef3106c | 544 | |
70f6d5e1 JJ |
545 | Wextra |
546 | C ObjC C++ ObjC++ Warning | |
547 | ; in common.opt | |
548 | ||
c3cbcd45 VR |
549 | Wextra-semi |
550 | C++ ObjC++ Var(warn_extra_semi) Warning | |
551 | Warn about semicolon after in-class function definition. | |
552 | ||
49b0aa18 | 553 | Wfloat-conversion |
63bbf46d | 554 | C ObjC C++ ObjC++ Var(warn_float_conversion) Warning LangEnabledBy(C ObjC C++ ObjC++,Wconversion) |
a7b2e184 | 555 | Warn for implicit type conversions that cause loss of floating point precision. |
49b0aa18 | 556 | |
fef3106c | 557 | Wfloat-equal |
c662432e | 558 | C ObjC C++ ObjC++ Var(warn_float_equal) Warning |
a7b2e184 | 559 | Warn if testing floating point numbers for equality. |
fef3106c NB |
560 | |
561 | Wformat | |
7332899a | 562 | C ObjC C++ ObjC++ Warning Alias(Wformat=, 1, 0) |
a7b2e184 | 563 | Warn about printf/scanf/strftime/strfmon format string anomalies. |
fef3106c | 564 | |
7332899a MLI |
565 | Wformat-contains-nul |
566 | C ObjC C++ ObjC++ Var(warn_format_contains_nul) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 1, 0) | |
a7b2e184 | 567 | Warn about format strings that contain NUL bytes. |
7332899a | 568 | |
a9c697b8 MS |
569 | Wformat-diag |
570 | C ObjC C++ ObjC++ Var(warn_format_diag) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 1, 0) | |
36b34127 | 571 | Warn about GCC format strings with strings unsuitable for diagnostics. |
a9c697b8 | 572 | |
fef3106c | 573 | Wformat-extra-args |
7332899a | 574 | C ObjC C++ ObjC++ Var(warn_format_extra_args) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 1, 0) |
a7b2e184 | 575 | Warn if passing too many arguments to a function for its format string. |
fef3106c NB |
576 | |
577 | Wformat-nonliteral | |
7332899a | 578 | C ObjC C++ ObjC++ Var(warn_format_nonliteral) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 2, 0) |
a7b2e184 | 579 | Warn about format strings that are not literals. |
fef3106c | 580 | |
bce6f760 | 581 | Wformat-overflow |
63010089 | 582 | C ObjC C++ LTO ObjC++ Warning Alias(Wformat-overflow=, 1, 0) IntegerRange(0, 2) |
bce6f760 MS |
583 | Warn about function calls with format strings that write past the end |
584 | of the destination region. Same as -Wformat-overflow=1. | |
585 | ||
fef3106c | 586 | Wformat-security |
7332899a | 587 | C ObjC C++ ObjC++ Var(warn_format_security) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=, warn_format >= 2, 0) |
a7b2e184 | 588 | Warn about possible security problems with format functions. |
fef3106c | 589 | |
cbbd2b1c | 590 | Wformat-signedness |
7631f0e2 | 591 | C ObjC C++ ObjC++ Var(warn_format_signedness) Warning |
a7b2e184 | 592 | Warn about sign differences with format functions. |
cbbd2b1c | 593 | |
efcc8d38 | 594 | Wformat-truncation |
bf5fbf46 | 595 | C ObjC C++ LTO ObjC++ Warning Alias(Wformat-truncation=, 1, 0) |
efcc8d38 MS |
596 | Warn about calls to snprintf and similar functions that truncate output. |
597 | Same as -Wformat-truncation=1. | |
598 | ||
fef3106c | 599 | Wformat-y2k |
7332899a | 600 | C ObjC C++ ObjC++ Var(warn_format_y2k) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=,warn_format >= 2, 0) |
a7b2e184 | 601 | Warn about strftime formats yielding 2-digit years. |
fef3106c NB |
602 | |
603 | Wformat-zero-length | |
7332899a | 604 | C ObjC C++ ObjC++ Var(warn_format_zero_length) Warning LangEnabledBy(C ObjC C++ ObjC++,Wformat=,warn_format >= 1, 0) |
a7b2e184 | 605 | Warn about zero-length formats. |
fef3106c NB |
606 | |
607 | Wformat= | |
63010089 | 608 | C ObjC C++ ObjC++ Joined RejectNegative UInteger Var(warn_format) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0) IntegerRange(0, 2) |
a7b2e184 | 609 | Warn about printf/scanf/strftime/strfmon format string anomalies. |
fef3106c | 610 | |
bce6f760 | 611 | Wformat-overflow= |
cea71f0a | 612 | C ObjC C++ LTO ObjC++ Joined RejectNegative UInteger Var(warn_format_overflow) Warning LangEnabledBy(C ObjC C++ LTO ObjC++,Wformat=, warn_format >= 1, 0) IntegerRange(0, 2) |
88d0c3f0 MS |
613 | Warn about function calls with format strings that write past the end |
614 | of the destination region. | |
615 | ||
efcc8d38 | 616 | Wformat-truncation= |
cea71f0a | 617 | C ObjC C++ LTO ObjC++ Joined RejectNegative UInteger Var(warn_format_trunc) Warning LangEnabledBy(C ObjC C++ LTO ObjC++,Wformat=, warn_format >= 1, 0) IntegerRange(0, 2) |
efcc8d38 MS |
618 | Warn about calls to snprintf and similar functions that truncate output. |
619 | ||
00aa1fa2 L |
620 | Wif-not-aligned |
621 | C ObjC C++ ObjC++ Var(warn_if_not_aligned) Init(1) Warning | |
622 | Warn when the field in a struct is not aligned. | |
623 | ||
5db2e9ca | 624 | Wignored-qualifiers |
95744782 | 625 | C C++ Var(warn_ignored_qualifiers) Warning EnabledBy(Wextra) |
5db2e9ca DK |
626 | Warn whenever type qualifiers are ignored. |
627 | ||
fbdb6baf MP |
628 | Wignored-attributes |
629 | C C++ Var(warn_ignored_attributes) Init(1) Warning | |
630 | Warn whenever attributes are ignored. | |
631 | ||
d3786ebb MB |
632 | Winaccessible-base |
633 | C++ ObjC++ Var(warn_inaccessible_base) Init(1) Warning | |
634 | Warn when a base is inaccessible in derived due to ambiguity. | |
635 | ||
d5c3d343 MP |
636 | Wincompatible-pointer-types |
637 | C ObjC Var(warn_incompatible_pointer_types) Init(1) Warning | |
a7b2e184 | 638 | Warn when there is a conversion between pointers that have incompatible types. |
d5c3d343 | 639 | |
da77eace L |
640 | Waddress-of-packed-member |
641 | C ObjC C++ ObjC++ Var(warn_address_of_packed_member) Init(1) Warning | |
642 | Warn when the address of packed member of struct or union is taken. | |
643 | ||
3390f9c9 | 644 | Winit-self |
0ccb505d | 645 | C ObjC C++ ObjC++ Var(warn_init_self) Warning LangEnabledBy(C++ ObjC++,Wall) |
a7b2e184 | 646 | Warn about variables which are initialized to themselves. |
3390f9c9 | 647 | |
04eb9c55 JM |
648 | Winit-list-lifetime |
649 | C++ ObjC++ Var(warn_init_list) Warning Init(1) | |
650 | Warn about uses of std::initializer_list that can result in dangling pointers. | |
651 | ||
fef3106c | 652 | Wimplicit |
4a0ae68e | 653 | C ObjC Var(warn_implicit) Warning LangEnabledBy(C ObjC,Wall) |
a7b2e184 | 654 | Warn about implicit declarations. |
fef3106c | 655 | |
70f6d5e1 JJ |
656 | Wimplicit-fallthrough= |
657 | LangEnabledBy(C ObjC C++ ObjC++,Wextra,3,0) | |
658 | ; in common.opt | |
659 | ||
0a0b3574 MM |
660 | Wdouble-promotion |
661 | C ObjC C++ ObjC++ Var(warn_double_promotion) Warning | |
a7b2e184 | 662 | Warn about implicit conversions from \"float\" to \"double\". |
0a0b3574 | 663 | |
fb2675cb PB |
664 | Wexpansion-to-defined |
665 | C ObjC C++ ObjC++ CPP(warn_expansion_to_defined) CppReason(CPP_W_EXPANSION_TO_DEFINED) Var(cpp_warn_expansion_to_defined) Init(0) Warning EnabledBy(Wextra || Wpedantic) | |
666 | Warn if \"defined\" is used outside #if. | |
667 | ||
fef3106c | 668 | Wimplicit-function-declaration |
4a0ae68e | 669 | C ObjC Var(warn_implicit_function_declaration) Init(-1) Warning LangEnabledBy(C ObjC,Wimplicit) |
a7b2e184 | 670 | Warn about implicit function declarations. |
fef3106c NB |
671 | |
672 | Wimplicit-int | |
92574c7c | 673 | C ObjC Var(warn_implicit_int) Init(-1) Warning LangEnabledBy(C ObjC,Wimplicit) |
a7b2e184 | 674 | Warn when a declaration does not specify a type. |
fef3106c NB |
675 | |
676 | Wimport | |
2d2bd949 | 677 | C ObjC C++ ObjC++ Undocumented Ignore |
fef3106c | 678 | |
4514a96b JM |
679 | Winherited-variadic-ctor |
680 | C++ ObjC++ Var(warn_inh_var_ctor) Init(1) Warning | |
a7b2e184 | 681 | Warn about C++11 inheriting constructors when the base has a variadic constructor. |
4514a96b | 682 | |
52ec0ea3 MP |
683 | Wint-conversion |
684 | C ObjC Var(warn_int_conversion) Init(1) Warning | |
a7b2e184 | 685 | Warn about incompatible integer to pointer and pointer to integer conversions. |
52ec0ea3 | 686 | |
144a96e4 BE |
687 | Wint-in-bool-context |
688 | C ObjC C++ ObjC++ Var(warn_int_in_bool_context) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
689 | Warn for suspicious integer expressions in boolean context. | |
690 | ||
53a2494e | 691 | Wint-to-pointer-cast |
dc8d2739 | 692 | C ObjC C++ ObjC++ Var(warn_int_to_pointer_cast) Init(1) Warning |
a7b2e184 | 693 | Warn when there is a cast to a pointer from an integer of a different size. |
53a2494e | 694 | |
fef3106c | 695 | Winvalid-offsetof |
c662432e | 696 | C++ ObjC++ Var(warn_invalid_offsetof) Init(1) Warning |
a7b2e184 | 697 | Warn about invalid uses of the \"offsetof\" macro. |
fef3106c NB |
698 | |
699 | Winvalid-pch | |
b559c810 | 700 | C ObjC C++ ObjC++ CPP(warn_invalid_pch) CppReason(CPP_W_INVALID_PCH) Var(cpp_warn_invalid_pch) Init(0) Warning |
a7b2e184 | 701 | Warn about PCH files that are found but not used. |
fef3106c | 702 | |
e1b7793c | 703 | Wjump-misses-init |
f2bc201f | 704 | C ObjC Var(warn_jump_misses_init) Warning LangEnabledby(C ObjC,Wc++-compat) |
a7b2e184 | 705 | Warn when a jump misses a variable initialization. |
e1b7793c | 706 | |
7f5f5f98 | 707 | Wliteral-suffix |
b559c810 | 708 | C++ ObjC++ CPP(warn_literal_suffix) CppReason(CPP_W_LITERAL_SUFFIX) Var(cpp_warn_literal_suffix) Init(1) Warning |
7f5f5f98 OW |
709 | Warn when a string or character literal is followed by a ud-suffix which does not begin with an underscore. |
710 | ||
ca409efd | 711 | Wlogical-op |
a7b2e184 MS |
712 | C ObjC C++ ObjC++ Var(warn_logical_op) Init(0) Warning |
713 | Warn when a logical operator is suspiciously always evaluating to true or false. | |
ca409efd | 714 | |
742938c9 | 715 | Wlogical-not-parentheses |
d2e4feca | 716 | C ObjC C++ ObjC++ Var(warn_logical_not_paren) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 717 | Warn when logical not is used on the left hand side operand of a comparison. |
742938c9 | 718 | |
fef3106c | 719 | Wlong-long |
b559c810 | 720 | C ObjC C++ ObjC++ CPP(cpp_warn_long_long) CppReason(CPP_W_LONG_LONG) Var(warn_long_long) Init(-1) Warning LangEnabledBy(C ObjC,Wc90-c99-compat) |
a7b2e184 | 721 | Do not warn about using \"long long\" when -pedantic. |
fef3106c NB |
722 | |
723 | Wmain | |
34a180a6 | 724 | C ObjC C++ ObjC++ Var(warn_main) Init(-1) Warning LangEnabledBy(C ObjC,Wall, 2, 0) |
a7b2e184 | 725 | Warn about suspicious declarations of \"main\". |
fef3106c | 726 | |
34a180a6 MLI |
727 | Wmain |
728 | LangEnabledBy(C ObjC C++ ObjC++,Wpedantic, 2, 0) | |
729 | ; | |
730 | ||
b108f48f JJ |
731 | Wmemset-transposed-args |
732 | C ObjC C++ ObjC++ Var(warn_memset_transposed_args) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 733 | Warn about suspicious calls to memset where the third argument is constant literal zero and the second is not. |
b108f48f | 734 | |
c1e1f433 BS |
735 | Wmemset-elt-size |
736 | C ObjC C++ ObjC++ Var(warn_memset_elt_size) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
737 | Warn about suspicious calls to memset where the third argument contains the number of elements not multiplied by the element size. | |
738 | ||
c3388e62 | 739 | Wmisleading-indentation |
f6069ccc | 740 | C C++ Common Var(warn_misleading_indentation) Warning LangEnabledBy(C C++,Wall) |
a7b2e184 | 741 | Warn when the indentation of the code does not reflect the block structure. |
c3388e62 | 742 | |
fef3106c | 743 | Wmissing-braces |
4f7f7aca | 744 | C ObjC C++ ObjC++ Var(warn_missing_braces) Warning LangEnabledBy(C ObjC,Wall) |
a7b2e184 | 745 | Warn about possibly missing braces around initializers. |
fef3106c NB |
746 | |
747 | Wmissing-declarations | |
c662432e | 748 | C ObjC C++ ObjC++ Var(warn_missing_declarations) Warning |
a7b2e184 | 749 | Warn about global functions without previous declarations. |
fef3106c | 750 | |
eaac4679 | 751 | Wmissing-field-initializers |
95744782 | 752 | C ObjC C++ ObjC++ Var(warn_missing_field_initializers) Warning EnabledBy(Wextra) |
a7b2e184 | 753 | Warn about missing fields in struct initializers. |
eaac4679 | 754 | |
3e2becc4 MP |
755 | Wmultistatement-macros |
756 | C ObjC C++ ObjC++ Var(warn_multistatement_macros) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
757 | Warn about unsafe macros expanding to multiple statements used as a body of a clause such as if, else, while, switch, or for. | |
758 | ||
6b333269 NS |
759 | Wmultiple-inheritance |
760 | C++ ObjC++ Var(warn_multiple_inheritance) Warning | |
a7b2e184 | 761 | Warn on direct multiple inheritance. |
6b333269 NS |
762 | |
763 | Wnamespaces | |
764 | C++ ObjC++ Var(warn_namespaces) Warning | |
a7b2e184 | 765 | Warn on namespace definition. |
6b333269 | 766 | |
00aa1fa2 L |
767 | Wpacked-not-aligned |
768 | C ObjC C++ ObjC++ Var(warn_packed_not_aligned) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
769 | Warn when fields in a struct with the packed attribute are misaligned. | |
770 | ||
20b06add JM |
771 | Wsized-deallocation |
772 | C++ ObjC++ Var(warn_sized_deallocation) Warning EnabledBy(Wextra) | |
a7b2e184 | 773 | Warn about missing sized deallocation functions. |
20b06add | 774 | |
40ffd95f BE |
775 | Wsizeof-pointer-div |
776 | C ObjC C++ ObjC++ Var(warn_sizeof_pointer_div) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
777 | Warn about suspicious divisions of two sizeof expressions that don't work correctly with pointers. | |
778 | ||
1a4049e7 | 779 | Wsizeof-pointer-memaccess |
4a0ae68e | 780 | C ObjC C++ ObjC++ Var(warn_sizeof_pointer_memaccess) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 781 | Warn about suspicious length parameters to certain string functions if the argument uses sizeof. |
1a4049e7 | 782 | |
773ec47f MP |
783 | Wsizeof-array-argument |
784 | C ObjC C++ ObjC++ Var(warn_sizeof_array_argument) Warning Init(1) | |
a7b2e184 | 785 | Warn when sizeof is applied on a parameter declared as an array. |
773ec47f | 786 | |
ee92e7ba | 787 | Wstringop-overflow |
cea71f0a | 788 | C ObjC C++ LTO ObjC++ Warning Alias(Wstringop-overflow=, 2, 0) |
ee92e7ba MS |
789 | Warn about buffer overflow in string manipulation functions like memcpy |
790 | and strcpy. | |
791 | ||
792 | Wstringop-overflow= | |
cea71f0a | 793 | C ObjC C++ LTO ObjC++ Joined RejectNegative UInteger Var(warn_stringop_overflow) Init(2) Warning LangEnabledBy(C ObjC C++ LTO ObjC++, Wall, 2, 0) IntegerRange(0, 4) |
ee92e7ba MS |
794 | Under the control of Object Size type, warn about buffer overflow in string |
795 | manipulation functions like memcpy and strcpy. | |
796 | ||
025d57f0 | 797 | Wstringop-truncation |
cea71f0a | 798 | C ObjC C++ LTO ObjC++ Var(warn_stringop_truncation) Warning Init (1) LangEnabledBy(C ObjC C++ LTO ObjC++, Wall) |
025d57f0 MS |
799 | Warn about truncation in string manipulation functions like strncat and strncpy. |
800 | ||
90137d8f MLI |
801 | Wsuggest-attribute=format |
802 | C ObjC C++ ObjC++ Var(warn_suggest_attribute_format) Warning | |
a7b2e184 | 803 | Warn about functions which might be candidates for format attributes. |
fef3106c | 804 | |
2f42e5de TS |
805 | Wsuggest-override |
806 | C++ ObjC++ Var(warn_override) Warning | |
807 | Suggest that the override keyword be used when the declaration of a virtual | |
808 | function overrides another. | |
809 | ||
34a180a6 MLI |
810 | Wswitch |
811 | C ObjC C++ ObjC++ Var(warn_switch) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 812 | Warn about enumerated switches, with no default, missing a case. |
34a180a6 MLI |
813 | |
814 | Wswitch-default | |
815 | C ObjC C++ ObjC++ Var(warn_switch_default) Warning | |
a7b2e184 | 816 | Warn about enumerated switches missing a \"default:\" statement. |
34a180a6 MLI |
817 | |
818 | Wswitch-enum | |
819 | C ObjC C++ ObjC++ Var(warn_switch_enum) Warning | |
a7b2e184 | 820 | Warn about all enumerated switches missing a specific case. |
34a180a6 | 821 | |
fedfecef | 822 | Wswitch-bool |
5c3d09f7 | 823 | C ObjC C++ ObjC++ Var(warn_switch_bool) Warning Init(1) |
a7b2e184 | 824 | Warn about switches with boolean controlling expression. |
fedfecef | 825 | |
da9e9b57 MB |
826 | Wswitch-outside-range |
827 | C ObjC C++ ObjC++ Var(warn_switch_outside_range) Warning Init(1) | |
828 | Warn about switch values that are outside of the switch's type range. | |
829 | ||
6b333269 NS |
830 | Wtemplates |
831 | C++ ObjC++ Var(warn_templates) Warning | |
a7b2e184 | 832 | Warn on primary template declaration. |
6b333269 | 833 | |
d4cfd486 MS |
834 | Wmissing-attributes |
835 | C ObjC C++ ObjC++ Var(warn_missing_attributes) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
836 | Warn about declarations of entities that may be missing attributes | |
d3a02ae5 | 837 | that related entities have been declared with. |
d4cfd486 | 838 | |
90137d8f | 839 | Wmissing-format-attribute |
54d62f51 | 840 | C ObjC C++ ObjC++ Warning Alias(Wsuggest-attribute=format) |
90137d8f MLI |
841 | ; |
842 | ||
b02398bd | 843 | Wmissing-include-dirs |
b559c810 | 844 | C ObjC C++ ObjC++ CPP(warn_missing_include_dirs) CppReason(CPP_W_MISSING_INCLUDE_DIRS) Var(cpp_warn_missing_include_dirs) Init(0) Warning |
a7b2e184 | 845 | Warn about user-specified include directories that do not exist. |
b02398bd | 846 | |
cb4af25a | 847 | Wmissing-parameter-type |
95744782 | 848 | C ObjC Var(warn_missing_parameter_type) Warning EnabledBy(Wextra) |
a7b2e184 | 849 | Warn about function parameters declared without a type specifier in K&R-style functions. |
cb4af25a | 850 | |
fef3106c | 851 | Wmissing-prototypes |
c662432e | 852 | C ObjC Var(warn_missing_prototypes) Warning |
a7b2e184 | 853 | Warn about global functions without prototypes. |
fef3106c | 854 | |
5720c0dc | 855 | Wmudflap |
c0c12356 | 856 | C ObjC C++ ObjC++ Deprecated |
5720c0dc | 857 | |
fef3106c | 858 | Wmultichar |
b559c810 | 859 | C ObjC C++ ObjC++ CPP(warn_multichar) CppReason(CPP_W_MULTICHAR) Var(cpp_warn_multichar) Init(0) Warning |
a7b2e184 | 860 | Warn about use of multi-character character constants. |
fef3106c | 861 | |
76f86d00 | 862 | Wnarrowing |
765189ff | 863 | C ObjC C++ ObjC++ Warning Var(warn_narrowing) Init(-1) LangEnabledBy(C++ ObjC++,Wall || Wc++11-compat) |
a7b2e184 | 864 | Warn about narrowing conversions within { } that are ill-formed in C++11. |
76f86d00 | 865 | |
fef3106c | 866 | Wnested-externs |
c662432e | 867 | C ObjC Var(warn_nested_externs) Warning |
a7b2e184 | 868 | Warn about \"extern\" declarations not at file scope. |
fef3106c | 869 | |
59f9c2ed JM |
870 | Wnoexcept |
871 | C++ ObjC++ Var(warn_noexcept) Warning | |
a7b2e184 | 872 | Warn when a noexcept expression evaluates to false even though the expression can't actually throw. |
59f9c2ed | 873 | |
108154ff | 874 | Wnoexcept-type |
7b936140 JJ |
875 | C++ ObjC++ Warning Var(warn_noexcept_type) LangEnabledBy(C++ ObjC++,Wabi || Wc++17-compat) |
876 | Warn if C++17 noexcept function type will change the mangled name of a symbol. | |
108154ff | 877 | |
fef3106c | 878 | Wnon-template-friend |
c662432e | 879 | C++ ObjC++ Var(warn_nontemplate_friend) Init(1) Warning |
a7b2e184 | 880 | Warn when non-templatized friend functions are declared within a template. |
fef3106c | 881 | |
a599af84 MP |
882 | Wclass-conversion |
883 | C++ ObjC++ Var(warn_class_conversion) Init(1) Warning | |
884 | Warn when a conversion function will never be called due to the type it converts to. | |
885 | ||
c3684b7b MS |
886 | Wclass-memaccess |
887 | C++ ObjC++ Var(warn_class_memaccess) Warning LangEnabledBy(C++ ObjC++, Wall) | |
888 | Warn for unsafe raw memory writes to objects of class types. | |
889 | ||
fef3106c | 890 | Wnon-virtual-dtor |
880a467b | 891 | C++ ObjC++ Var(warn_nonvdtor) Warning LangEnabledBy(C++ ObjC++,Weffc++) |
a7b2e184 | 892 | Warn about non-virtual destructors. |
fef3106c NB |
893 | |
894 | Wnonnull | |
cea71f0a | 895 | C ObjC C++ LTO ObjC++ Var(warn_nonnull) Warning LangEnabledBy(C ObjC C++ LTO ObjC++,Wformat=,warn_format >= 1,0) |
a7b2e184 | 896 | Warn about NULL being passed to argument slots marked as requiring non-NULL. |
fef3106c | 897 | |
7332899a | 898 | Wnonnull |
cea71f0a | 899 | C ObjC C++ LTO ObjC++ LangEnabledBy(C ObjC C++ LTO ObjC++,Wall) |
7332899a MLI |
900 | ; |
901 | ||
bf14eba2 JJ |
902 | Wnonnull-compare |
903 | C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
904 | ; | |
905 | ||
1ef33fd4 | 906 | Wnormalized |
54d62f51 | 907 | C ObjC C++ ObjC++ Warning Alias(Wnormalized=,nfc,none) |
1ef33fd4 MLI |
908 | ; |
909 | ||
50668cf6 | 910 | Wnormalized= |
b559c810 | 911 | C ObjC C++ ObjC++ RejectNegative Joined Warning CPP(warn_normalize) CppReason(CPP_W_NORMALIZE) Init(normalized_C) Var(cpp_warn_normalize) Enum(cpp_normalize_level) |
54dcd526 | 912 | -Wnormalized=[none|id|nfc|nfkc] Warn about non-normalized Unicode strings. |
1ef33fd4 MLI |
913 | |
914 | ; Required for these enum values. | |
915 | SourceInclude | |
916 | cpplib.h | |
917 | ||
918 | Enum | |
919 | Name(cpp_normalize_level) Type(int) UnknownError(argument %qs to %<-Wnormalized%> not recognized) | |
920 | ||
921 | EnumValue | |
922 | Enum(cpp_normalize_level) String(none) Value(normalized_none) | |
923 | ||
924 | EnumValue | |
925 | Enum(cpp_normalize_level) String(nfkc) Value(normalized_KC) | |
926 | ||
927 | EnumValue | |
928 | Enum(cpp_normalize_level) String(id) Value(normalized_identifier_C) | |
929 | ||
930 | EnumValue | |
931 | Enum(cpp_normalize_level) String(nfc) Value(normalized_C) | |
50668cf6 | 932 | |
fef3106c | 933 | Wold-style-cast |
c662432e | 934 | C++ ObjC++ Var(warn_old_style_cast) Warning |
a7b2e184 | 935 | Warn if a C-style cast is used in a program. |
fef3106c | 936 | |
b1ed4cb4 | 937 | Wold-style-declaration |
95744782 | 938 | C ObjC Var(warn_old_style_declaration) Warning EnabledBy(Wextra) |
a7b2e184 | 939 | Warn for obsolescent usage in a declaration. |
b1ed4cb4 | 940 | |
c034f121 | 941 | Wold-style-definition |
c662432e | 942 | C ObjC Var(warn_old_style_definition) Warning |
a7b2e184 | 943 | Warn if an old-style parameter definition is used. |
c034f121 | 944 | |
8b5e1202 SO |
945 | Wopenmp-simd |
946 | C C++ Var(warn_openmp_simd) Warning LangEnabledBy(C C++,Wall) | |
a7b2e184 | 947 | Warn if a simd directive is overridden by the vectorizer cost model. |
8b5e1202 | 948 | |
89a42ac8 | 949 | Woverlength-strings |
34a180a6 | 950 | C ObjC C++ ObjC++ Var(warn_overlength_strings) Warning LangEnabledBy(C ObjC C++ ObjC++,Wpedantic) |
a7b2e184 | 951 | Warn if a string is longer than the maximum portable length specified by the standard. |
89a42ac8 | 952 | |
fef3106c | 953 | Woverloaded-virtual |
c662432e | 954 | C++ ObjC++ Var(warn_overloaded_virtual) Warning |
a7b2e184 | 955 | Warn about overloaded virtual function names. |
fef3106c | 956 | |
7ed322d7 | 957 | Woverride-init |
95744782 | 958 | C ObjC Var(warn_override_init) Warning EnabledBy(Wextra) |
a7b2e184 | 959 | Warn about overriding initializers without side effects. |
7ed322d7 | 960 | |
755e528f MP |
961 | Woverride-init-side-effects |
962 | C ObjC Var(warn_override_init_side_effects) Init(1) Warning | |
a7b2e184 | 963 | Warn about overriding initializers with side effects. |
755e528f | 964 | |
2cd36c22 | 965 | Wpacked-bitfield-compat |
bee6fa6d | 966 | C ObjC C++ ObjC++ Var(warn_packed_bitfield_compat) Init(-1) Warning |
a7b2e184 | 967 | Warn about packed bit-fields whose offset changed in GCC 4.4. |
2cd36c22 | 968 | |
fef3106c | 969 | Wparentheses |
4a0ae68e | 970 | C ObjC C++ ObjC++ Var(warn_parentheses) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 971 | Warn about possibly missing parentheses. |
fef3106c | 972 | |
c1771a20 | 973 | Wpedantic |
b559c810 | 974 | C ObjC C++ ObjC++ CPP(cpp_pedantic) CppReason(CPP_W_PEDANTIC) Warning |
c1771a20 MLI |
975 | ; Documented in common.opt |
976 | ||
79ca9c35 MP |
977 | Wpessimizing-move |
978 | C++ ObjC++ Var(warn_pessimizing_move) Warning LangEnabledBy(C++ ObjC++, Wall) | |
979 | Warn about calling std::move on a local object in a return statement preventing copy elision. | |
980 | ||
fef3106c | 981 | Wpmf-conversions |
c662432e | 982 | C++ ObjC++ Var(warn_pmf2ptr) Init(1) Warning |
a7b2e184 | 983 | Warn when converting the type of pointers to member functions. |
fef3106c NB |
984 | |
985 | Wpointer-arith | |
44d90fe1 | 986 | C ObjC C++ ObjC++ Var(warn_pointer_arith) Warning LangEnabledBy(C ObjC C++ ObjC++,Wpedantic) |
a7b2e184 | 987 | Warn about function pointer arithmetic. |
fef3106c | 988 | |
4a0ae68e | 989 | Wpointer-sign |
27e51192 | 990 | C ObjC Var(warn_pointer_sign) Warning LangEnabledBy(C ObjC,Wall || Wpedantic) |
a7b2e184 | 991 | Warn when a pointer differs in signedness in an assignment. |
4a0ae68e | 992 | |
a9342885 MP |
993 | Wpointer-compare |
994 | C ObjC C++ ObjC++ Var(warn_pointer_compare) Init(1) Warning | |
995 | Warn when a pointer is compared with a zero character constant. | |
996 | ||
53a2494e | 997 | Wpointer-to-int-cast |
c662432e | 998 | C ObjC Var(warn_pointer_to_int_cast) Init(1) Warning |
a7b2e184 | 999 | Warn when a pointer is cast to an integer of a different size. |
53a2494e | 1000 | |
b9b8dde3 | 1001 | Wpragmas |
c662432e | 1002 | C ObjC C++ ObjC++ Var(warn_pragmas) Init(1) Warning |
a7b2e184 | 1003 | Warn about misuses of pragmas. |
b9b8dde3 | 1004 | |
8cff0652 VK |
1005 | Wprio-ctor-dtor |
1006 | C ObjC C++ ObjC++ Var(warn_prio_ctor_dtor) Init(1) Warning | |
1007 | Warn if constructor or destructors with priorities from 0 to 100 are used. | |
1008 | ||
9a179d01 NP |
1009 | Wproperty-assign-default |
1010 | ObjC ObjC++ Var(warn_property_assign_default) Init(1) Warning | |
a7b2e184 | 1011 | Warn if a property for an Objective-C object has no assign semantics specified. |
9a179d01 | 1012 | |
fef3106c | 1013 | Wprotocol |
c662432e | 1014 | ObjC ObjC++ Var(warn_protocol) Init(1) Warning |
a7b2e184 | 1015 | Warn if inherited methods are unimplemented. |
fef3106c | 1016 | |
e2f5cc96 | 1017 | Wplacement-new |
46cb9332 MS |
1018 | C++ Warning Alias(Wplacement-new=, 1, 0) |
1019 | Warn for placement new expressions with undefined behavior. | |
1020 | ||
1021 | Wplacement-new= | |
63010089 | 1022 | C++ Joined RejectNegative UInteger Var(warn_placement_new) Init(-1) Warning IntegerRange(0, 2) |
eb11eb15 | 1023 | Warn for placement new expressions with undefined behavior. |
e2f5cc96 | 1024 | |
fef3106c | 1025 | Wredundant-decls |
c662432e | 1026 | C ObjC C++ ObjC++ Var(warn_redundant_decls) Warning |
a7b2e184 | 1027 | Warn about multiple declarations of the same object. |
fef3106c | 1028 | |
b5be6d0c MP |
1029 | Wredundant-move |
1030 | C++ ObjC++ Var(warn_redundant_move) Warning LangEnabledBy(C++ ObjC++,Wextra) | |
1031 | Warn about redundant calls to std::move. | |
1032 | ||
a2c6e7f2 JJ |
1033 | Wregister |
1034 | C++ ObjC++ Var(warn_register) Warning | |
1035 | Warn about uses of register storage specifier. | |
1036 | ||
fef3106c | 1037 | Wreorder |
f2bc201f | 1038 | C++ ObjC++ Var(warn_reorder) Warning LangEnabledBy(C++ ObjC++,Wall) |
a7b2e184 | 1039 | Warn when the compiler reorders code. |
fef3106c NB |
1040 | |
1041 | Wreturn-type | |
1b6fa695 | 1042 | C ObjC C++ ObjC++ Var(warn_return_type) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) Init(-1) |
a7b2e184 | 1043 | Warn whenever a function's return type defaults to \"int\" (C), or about inconsistent return types (C++). |
fef3106c | 1044 | |
ee45a32d EB |
1045 | Wscalar-storage-order |
1046 | C ObjC C++ ObjC++ Init(1) Warning | |
1047 | Warn on suspicious constructs involving reverse scalar storage order. | |
1048 | ||
fef3106c | 1049 | Wselector |
c662432e | 1050 | ObjC ObjC++ Var(warn_selector) Warning |
a7b2e184 | 1051 | Warn if a selector has multiple methods. |
fef3106c | 1052 | |
13c21655 PC |
1053 | Wsequence-point |
1054 | C ObjC C++ ObjC++ Var(warn_sequence_point) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 1055 | Warn about possible violations of sequence point rules. |
13c21655 | 1056 | |
dcaaa5a0 | 1057 | Wshadow-ivar |
dff8943f | 1058 | ObjC ObjC++ Var(warn_shadow_ivar) EnabledBy(Wshadow) Init(1) Warning |
a7b2e184 | 1059 | Warn if a local declaration hides an instance variable. |
dcaaa5a0 | 1060 | |
451b5e48 MP |
1061 | Wshift-overflow |
1062 | C ObjC C++ ObjC++ Warning Alias(Wshift-overflow=, 1, 0) | |
a7b2e184 | 1063 | Warn if left shift of a signed value overflows. |
451b5e48 MP |
1064 | |
1065 | Wshift-overflow= | |
63010089 | 1066 | C ObjC C++ ObjC++ Joined RejectNegative UInteger Var(warn_shift_overflow) Init(-1) Warning IntegerRange(0, 2) |
a7b2e184 | 1067 | Warn if left shift of a signed value overflows. |
451b5e48 | 1068 | |
13c21655 PC |
1069 | Wshift-count-negative |
1070 | C ObjC C++ ObjC++ Var(warn_shift_count_negative) Init(1) Warning | |
a7b2e184 | 1071 | Warn if shift count is negative. |
13c21655 PC |
1072 | |
1073 | Wshift-count-overflow | |
1074 | C ObjC C++ ObjC++ Var(warn_shift_count_overflow) Init(1) Warning | |
a7b2e184 | 1075 | Warn if shift count >= width of type. |
fef3106c | 1076 | |
0173bd2a MP |
1077 | Wshift-negative-value |
1078 | C ObjC C++ ObjC++ Var(warn_shift_negative_value) Init(-1) Warning | |
a7b2e184 | 1079 | Warn if left shifting a negative value. |
0173bd2a | 1080 | |
fef3106c | 1081 | Wsign-compare |
4a0ae68e | 1082 | C ObjC C++ ObjC++ Var(warn_sign_compare) Warning LangEnabledBy(C++ ObjC++,Wall) |
a7b2e184 | 1083 | Warn about signed-unsigned comparisons. |
fef3106c | 1084 | |
4a0ae68e MLI |
1085 | Wsign-compare |
1086 | C ObjC C++ ObjC++ EnabledBy(Wextra) | |
1087 | ; | |
1088 | ||
1089 | Wsign-conversion | |
63bbf46d | 1090 | C ObjC C++ ObjC++ Var(warn_sign_conversion) Warning LangEnabledBy(C ObjC,Wconversion) |
a7b2e184 | 1091 | Warn for implicit type conversions between signed and unsigned integers. |
4a0ae68e | 1092 | |
fef3106c | 1093 | Wsign-promo |
c662432e | 1094 | C++ ObjC++ Var(warn_sign_promo) Warning |
a7b2e184 | 1095 | Warn when overload promotes from unsigned to signed. |
fef3106c | 1096 | |
b2f97e4a | 1097 | Wstrict-null-sentinel |
5498f011 | 1098 | C++ ObjC++ Warning Var(warn_strict_null_sentinel) |
a7b2e184 | 1099 | Warn about uncasted NULL used as sentinel. |
b2f97e4a | 1100 | |
fef3106c | 1101 | Wstrict-prototypes |
c662432e | 1102 | C ObjC Var(warn_strict_prototypes) Warning |
a7b2e184 | 1103 | Warn about unprototyped function declarations. |
fef3106c | 1104 | |
65d4f2cd | 1105 | Wstrict-aliasing= |
63010089 | 1106 | C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 3, 0) IntegerRange(0, 3) |
65d4f2cd MLI |
1107 | ; |
1108 | ||
1109 | Wstrict-overflow= | |
63010089 | 1110 | C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0) IntegerRange(0, 5) |
65d4f2cd MLI |
1111 | ; |
1112 | ||
6e955430 | 1113 | Wstrict-selector-match |
c662432e | 1114 | ObjC ObjC++ Var(warn_strict_selector_match) Warning |
a7b2e184 | 1115 | Warn if type signatures of candidate methods do not match exactly. |
6e955430 | 1116 | |
23462d4d UB |
1117 | Wsync-nand |
1118 | C C++ Var(warn_sync_nand) Init(1) Warning | |
a7b2e184 | 1119 | Warn when __sync_fetch_and_nand and __sync_nand_and_fetch built-in functions are used. |
23462d4d | 1120 | |
fef3106c | 1121 | Wsynth |
c662432e | 1122 | C++ ObjC++ Var(warn_synth) Warning |
a7b2e184 | 1123 | Deprecated. This switch has no effect. |
fef3106c NB |
1124 | |
1125 | Wsystem-headers | |
c662432e | 1126 | C ObjC C++ ObjC++ Warning |
9a0f3e86 | 1127 | ; Documented in common.opt |
fef3106c | 1128 | |
05b28fd6 MP |
1129 | Wtautological-compare |
1130 | C ObjC C++ ObjC++ Var(warn_tautological_compare) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
a7b2e184 | 1131 | Warn if a comparison always evaluates to true or false. |
05b28fd6 | 1132 | |
8243e2a9 JM |
1133 | Wterminate |
1134 | C++ ObjC++ Warning Var(warn_terminate) Init(1) | |
a7b2e184 | 1135 | Warn if a throw expression will always result in a call to terminate(). |
8243e2a9 | 1136 | |
fef3106c | 1137 | Wtraditional |
b559c810 | 1138 | C ObjC CPP(cpp_warn_traditional) CppReason(CPP_W_TRADITIONAL) Var(warn_traditional) Init(0) Warning |
a7b2e184 | 1139 | Warn about features not present in traditional C. |
fef3106c | 1140 | |
05170031 | 1141 | Wtraditional-conversion |
c662432e | 1142 | C ObjC Var(warn_traditional_conversion) Warning |
a7b2e184 | 1143 | Warn of prototypes causing type conversions different from what would happen in the absence of prototype. |
05170031 | 1144 | |
fef3106c | 1145 | Wtrigraphs |
b559c810 | 1146 | C ObjC C++ ObjC++ CPP(warn_trigraphs) CppReason(CPP_W_TRIGRAPHS) Var(cpp_warn_trigraphs) Init(2) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 1147 | Warn if trigraphs are encountered that might affect the meaning of the program. |
fef3106c NB |
1148 | |
1149 | Wundeclared-selector | |
c662432e | 1150 | ObjC ObjC++ Var(warn_undeclared_selector) Warning |
a7b2e184 | 1151 | Warn about @selector()s without previously declared methods. |
fef3106c NB |
1152 | |
1153 | Wundef | |
b559c810 | 1154 | C ObjC C++ ObjC++ CPP(warn_undef) CppReason(CPP_W_UNDEF) Var(cpp_warn_undef) Init(0) Warning |
a7b2e184 | 1155 | Warn if an undefined macro is used in an #if directive. |
fef3106c | 1156 | |
4a0ae68e | 1157 | Wuninitialized |
cea71f0a | 1158 | C ObjC C++ ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall) |
4a0ae68e MLI |
1159 | ; |
1160 | ||
1161 | Wmaybe-uninitialized | |
cea71f0a | 1162 | C ObjC C++ ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall) |
4a0ae68e MLI |
1163 | ; |
1164 | ||
fef3106c | 1165 | Wunknown-pragmas |
34a180a6 | 1166 | C ObjC C++ ObjC++ Warning Var(warn_unknown_pragmas) LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0) |
a7b2e184 | 1167 | Warn about unrecognized pragmas. |
fef3106c | 1168 | |
6ec637a4 JJ |
1169 | Wunsuffixed-float-constants |
1170 | C ObjC Var(warn_unsuffixed_float_constants) Warning | |
a7b2e184 | 1171 | Warn about unsuffixed float constants. |
6ec637a4 | 1172 | |
4a0ae68e MLI |
1173 | Wunused |
1174 | C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall) | |
1175 | ; documented in common.opt | |
1176 | ||
3797cb21 | 1177 | Wunused-local-typedefs |
650dc14a | 1178 | C ObjC C++ ObjC++ Var(warn_unused_local_typedefs) Warning EnabledBy(Wunused) |
a7b2e184 | 1179 | Warn when typedefs locally defined in a function are not used. |
3797cb21 | 1180 | |
fef3106c | 1181 | Wunused-macros |
b559c810 | 1182 | C ObjC C++ ObjC++ CppReason(CPP_W_UNUSED_MACROS) Var(cpp_warn_unused_macros) Warning |
a7b2e184 | 1183 | Warn about macros defined in the main file that are not used. |
fef3106c | 1184 | |
156f545a MLI |
1185 | Wunused-result |
1186 | C ObjC C++ ObjC++ Var(warn_unused_result) Init(1) Warning | |
a7b2e184 | 1187 | Warn if a caller of a function, marked with attribute warn_unused_result, does not use its return value. |
156f545a | 1188 | |
0f876f22 MW |
1189 | Wunused-variable |
1190 | C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wunused) | |
1191 | ; documented in common.opt | |
1192 | ||
1193 | Wunused-const-variable | |
4246c8da MW |
1194 | C ObjC C++ ObjC++ Warning Alias(Wunused-const-variable=, 2, 0) |
1195 | Warn when a const variable is unused. | |
1196 | ||
1197 | Wunused-const-variable= | |
63010089 | 1198 | C ObjC C++ ObjC++ Joined RejectNegative UInteger Var(warn_unused_const_variable) Warning LangEnabledBy(C ObjC,Wunused-variable, 1, 0) IntegerRange(0, 2) |
a7b2e184 | 1199 | Warn when a const variable is unused. |
0f876f22 | 1200 | |
e5b79219 | 1201 | Wvariadic-macros |
27e51192 | 1202 | C ObjC C++ ObjC++ CPP(warn_variadic_macros) CppReason(CPP_W_VARIADIC_MACROS) Var(cpp_warn_variadic_macros) Init(0) Warning LangEnabledBy(C ObjC C++ ObjC++,Wpedantic || Wtraditional) |
a7b2e184 | 1203 | Warn about using variadic macros. |
e5b79219 | 1204 | |
b9c8da34 DS |
1205 | Wvarargs |
1206 | C ObjC C++ ObjC++ Warning Var(warn_varargs) Init(1) | |
a7b2e184 | 1207 | Warn about questionable usage of the macros used to retrieve variable arguments. |
b9c8da34 | 1208 | |
50d50fc7 SP |
1209 | Wvla |
1210 | C ObjC C++ ObjC++ Var(warn_vla) Init(-1) Warning | |
a7b2e184 | 1211 | Warn if a variable length array is used. |
50d50fc7 | 1212 | |
adc577c5 | 1213 | Wvla-larger-than= |
00abf86c MS |
1214 | C ObjC C++ LTO ObjC++ Var(warn_vla_limit) Warning Joined Host_Wide_Int ByteSize Init(HOST_WIDE_INT_MAX) |
1215 | -Wvla-larger-than=<number> Warn on unbounded uses of variable-length | |
1216 | arrays, and on bounded uses of variable-length arrays whose bound can be | |
adc577c5 | 1217 | larger than <number> bytes. |
00abf86c MS |
1218 | <number> bytes. |
1219 | ||
1220 | Wno-vla-larger-than | |
1221 | C ObjC C++ LTO ObjC++ Alias(Wvla-larger-than=,18446744073709551615EiB,none) Warning | |
1222 | -Wno-vla-larger-than Disable Wvla-larger-than= warning. Equivalent to Wvla-larger-than=<SIZE_MAX> or larger. | |
adc577c5 | 1223 | |
16302daf | 1224 | Wvolatile-register-var |
4a0ae68e | 1225 | C ObjC C++ ObjC++ Var(warn_volatile_register_var) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) |
a7b2e184 | 1226 | Warn when a register variable is declared volatile. |
16302daf | 1227 | |
6b333269 NS |
1228 | Wvirtual-inheritance |
1229 | C++ ObjC++ Var(warn_virtual_inheritance) Warning | |
a7b2e184 | 1230 | Warn on direct virtual inheritance. |
6b333269 | 1231 | |
f14edc1a JM |
1232 | Wvirtual-move-assign |
1233 | C++ ObjC++ Var(warn_virtual_move_assign) Warning Init(1) | |
a7b2e184 | 1234 | Warn if a virtual base has a non-trivial move assignment operator. |
f14edc1a | 1235 | |
fef3106c | 1236 | Wwrite-strings |
c662432e | 1237 | C ObjC C++ ObjC++ Var(warn_write_strings) Warning |
d8a07487 | 1238 | In C++, nonzero means warn about deprecated conversion from string literals to 'char *'. In C, similar warning, except that the conversion is of course not deprecated by the ISO C standard. |
fef3106c | 1239 | |
89401152 PC |
1240 | Wzero-as-null-pointer-constant |
1241 | C++ ObjC++ Var(warn_zero_as_null_pointer_constant) Warning | |
a7b2e184 | 1242 | Warn when a literal '0' is used as null pointer. |
89401152 | 1243 | |
04398fa8 PC |
1244 | Wuseless-cast |
1245 | C++ ObjC++ Var(warn_useless_cast) Warning | |
a7b2e184 | 1246 | Warn about useless casts. |
04398fa8 | 1247 | |
273aa49e PC |
1248 | Wsubobject-linkage |
1249 | C++ ObjC++ Var(warn_subobject_linkage) Warning Init(1) | |
a7b2e184 | 1250 | Warn if a class type has a base or a field whose type uses the anonymous namespace or depends on a type with no linkage. |
273aa49e | 1251 | |
d6e83a8d MM |
1252 | Wduplicate-decl-specifier |
1253 | C ObjC Var(warn_duplicate_decl_specifier) Warning LangEnabledBy(C ObjC,Wall) | |
1254 | Warn when a declaration has duplicate const, volatile, restrict or _Atomic specifier. | |
1255 | ||
975672f3 | 1256 | Wrestrict |
cc8bea0a | 1257 | C ObjC C++ ObjC++ Var(warn_restrict) Warning LangEnabledBy(C ObjC C++ ObjC++, Wall) |
975672f3 PK |
1258 | Warn when an argument passed to a restrict-qualified parameter aliases with |
1259 | another argument. | |
1260 | ||
fef3106c NB |
1261 | ansi |
1262 | C ObjC C++ ObjC++ | |
a7b2e184 | 1263 | A synonym for -std=c89 (for C) or -std=c++98 (for C++). |
fef3106c NB |
1264 | |
1265 | d | |
1266 | C ObjC C++ ObjC++ Joined | |
72de27ea | 1267 | ; Documented in common.opt. FIXME - what about -dI, -dD, -dN and -dD? |
fef3106c | 1268 | |
62984918 JM |
1269 | fabi-compat-version= |
1270 | C++ ObjC++ Joined RejectNegative UInteger Var(flag_abi_compat_version) Init(-1) | |
a7b2e184 | 1271 | The version of the C++ ABI used for -Wabi warnings and link compatibility aliases. |
62984918 | 1272 | |
fef3106c | 1273 | faccess-control |
5498f011 | 1274 | C++ ObjC++ Var(flag_access_control) Init(1) |
a7b2e184 | 1275 | Enforce class member access control semantics. |
fef3106c | 1276 | |
da5182be TQ |
1277 | fada-spec-parent= |
1278 | C ObjC C++ ObjC++ RejectNegative Joined Var(ada_specs_parent) | |
a7b2e184 | 1279 | -fada-spec-parent=unit Dump Ada specs as child units of given parent. |
da5182be | 1280 | |
af63ba4b JM |
1281 | faligned-new |
1282 | C++ ObjC++ Alias(faligned-new=,1,0) | |
1283 | Support C++17 allocation of over-aligned types. | |
1284 | ||
1285 | faligned-new= | |
2e1c20b1 | 1286 | C++ ObjC++ Joined RejectNegative Var(aligned_new_threshold) UInteger Init(-1) |
af63ba4b JM |
1287 | -faligned-new=<N> Use C++17 over-aligned type allocation for alignments greater than N. |
1288 | ||
fef3106c | 1289 | fall-virtual |
c0c12356 | 1290 | C++ ObjC++ Deprecated |
fef3106c | 1291 | |
6637388f TG |
1292 | fallow-parameterless-variadic-functions |
1293 | C ObjC Var(flag_allow_parameterless_variadic_functions) | |
a7b2e184 | 1294 | Allow variadic functions without named parameter. |
6637388f | 1295 | |
fef3106c | 1296 | falt-external-templates |
c0c12356 | 1297 | C++ ObjC++ Deprecated |
a7b2e184 | 1298 | No longer supported. |
fef3106c NB |
1299 | |
1300 | fasm | |
5498f011 | 1301 | C ObjC C++ ObjC++ Var(flag_no_asm, 0) |
a7b2e184 | 1302 | Recognize the \"asm\" keyword. |
fef3106c | 1303 | |
10e48e39 RO |
1304 | ; Define extra predefined macros for use in libgcc. |
1305 | fbuilding-libgcc | |
1306 | C ObjC C++ ObjC++ Undocumented Var(flag_building_libgcc) | |
1307 | ||
fef3106c | 1308 | fbuiltin |
5498f011 | 1309 | C ObjC C++ ObjC++ Var(flag_no_builtin, 0) |
a7b2e184 | 1310 | Recognize built-in functions. |
fef3106c NB |
1311 | |
1312 | fbuiltin- | |
1313 | C ObjC C++ ObjC++ Joined | |
1314 | ||
5dc99c46 SB |
1315 | fcanonical-system-headers |
1316 | C ObjC C++ ObjC++ | |
1317 | Where shorter, use canonicalized paths to systems headers. | |
1318 | ||
2d91f79d TH |
1319 | fchar8_t |
1320 | C++ ObjC++ Var(flag_char8_t) Init(-1) | |
1321 | Enable the char8_t fundamental type and use it as the type for UTF-8 string | |
1322 | and character literals. | |
1323 | ||
d5e254e1 | 1324 | fcheck-pointer-bounds |
c0c12356 | 1325 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1326 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1327 | |
1328 | fchkp-check-incomplete-type | |
c0c12356 | 1329 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1330 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1331 | |
1332 | fchkp-zero-input-bounds-for-main | |
c0c12356 | 1333 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1334 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1335 | |
1336 | fchkp-first-field-has-own-bounds | |
c0c12356 | 1337 | C ObjC C++ ObjC++ LTO Deprecated RejectNegative |
31db0fe0 | 1338 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1339 | |
1340 | fchkp-narrow-bounds | |
c0c12356 | 1341 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1342 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1343 | |
1344 | fchkp-narrow-to-innermost-array | |
c0c12356 | 1345 | C ObjC C++ ObjC++ LTO Deprecated RejectNegative |
31db0fe0 | 1346 | Deprecated in GCC 9. This switch has no effect. |
8ba4f506 AI |
1347 | |
1348 | fchkp-flexible-struct-trailing-arrays | |
c0c12356 | 1349 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1350 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1351 | |
1352 | fchkp-optimize | |
c0c12356 | 1353 | C ObjC C++ ObjC++ LTO Deprecated |
d5e254e1 IE |
1354 | |
1355 | fchkp-use-fast-string-functions | |
c0c12356 | 1356 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1357 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1358 | |
1359 | fchkp-use-nochk-string-functions | |
c0c12356 | 1360 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1361 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1362 | |
1363 | fchkp-use-static-bounds | |
c0c12356 | 1364 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1365 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1366 | |
1367 | fchkp-use-static-const-bounds | |
c0c12356 | 1368 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1369 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1370 | |
1371 | fchkp-treat-zero-dynamic-size-as-infinite | |
c0c12356 | 1372 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1373 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1374 | |
1375 | fchkp-check-read | |
c0c12356 | 1376 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1377 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1378 | |
1379 | fchkp-check-write | |
c0c12356 | 1380 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1381 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1382 | |
1383 | fchkp-store-bounds | |
c0c12356 | 1384 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1385 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1386 | |
1387 | fchkp-instrument-calls | |
c0c12356 | 1388 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1389 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 IE |
1390 | |
1391 | fchkp-instrument-marked-only | |
c0c12356 | 1392 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1393 | Deprecated in GCC 9. This switch has no effect. |
d5e254e1 | 1394 | |
226d62d2 | 1395 | fchkp-use-wrappers |
c0c12356 | 1396 | C ObjC C++ ObjC++ LTO Deprecated |
31db0fe0 | 1397 | Deprecated in GCC 9. This switch has no effect. |
226d62d2 | 1398 | |
5373cd33 | 1399 | static-libmpx |
3713f2e2 | 1400 | Driver Deprecated |
31db0fe0 | 1401 | Deprecated in GCC 9. This switch has no effect. |
5373cd33 | 1402 | |
d2d7e672 | 1403 | static-libmpxwrappers |
3713f2e2 | 1404 | Driver Deprecated |
31db0fe0 | 1405 | Deprecated in GCC 9. This switch has no effect. |
d2d7e672 | 1406 | |
c0c12356 ML |
1407 | fcilkplus |
1408 | C ObjC C++ ObjC++ LTO Undocumented Ignore | |
5e9d6aa4 | 1409 | Deprecated in GCC 8. This switch has no effect. |
36536d79 | 1410 | |
971e17ff AS |
1411 | fconcepts |
1412 | C++ ObjC++ Var(flag_concepts) | |
a7b2e184 | 1413 | Enable support for C++ concepts. |
971e17ff | 1414 | |
fef3106c NB |
1415 | fcond-mismatch |
1416 | C ObjC C++ ObjC++ | |
a7b2e184 | 1417 | Allow the arguments of the '?' operator to have different types. |
fef3106c NB |
1418 | |
1419 | fconserve-space | |
c0c12356 | 1420 | C++ ObjC++ Ignore |
6f07a821 | 1421 | Does nothing. Preserved for backward compatibility. |
fef3106c | 1422 | |
fef3106c | 1423 | fconstant-string-class= |
61ff2bdc | 1424 | ObjC ObjC++ Joined MissingArgError(no class name specified with %qs) |
a7b2e184 | 1425 | -fconst-string-class=<name> Use class <name> for constant strings. |
fef3106c | 1426 | |
17bc631c | 1427 | fconstexpr-depth= |
49a000c3 | 1428 | C++ ObjC++ Joined RejectNegative UInteger Var(max_constexpr_depth) Init(512) |
a7b2e184 | 1429 | -fconstexpr-depth=<number> Specify maximum constexpr recursion depth. |
17bc631c | 1430 | |
7ffc7de5 JM |
1431 | fconstexpr-cache-depth= |
1432 | C++ ObjC++ Joined RejectNegative UInteger Var(constexpr_cache_depth) Init(8) | |
1433 | -fconstexpr-cache-depth=<number> Specify maximum constexpr recursion cache depth. | |
1434 | ||
5ec2cd9f JM |
1435 | fconstexpr-loop-limit= |
1436 | C++ ObjC++ Joined RejectNegative UInteger Var(constexpr_loop_limit) Init(262144) | |
1437 | -fconstexpr-loop-limit=<number> Specify maximum constexpr loop iteration count. | |
1438 | ||
a15ffa22 JJ |
1439 | fconstexpr-ops-limit= |
1440 | C++ ObjC++ Joined RejectNegative Host_Wide_Int Var(constexpr_ops_limit) Init(33554432) | |
1441 | -fconstexpr-ops-limit=<number> Specify maximum number of constexpr operations during a single constexpr evaluation. | |
1442 | ||
847e697a TT |
1443 | fdebug-cpp |
1444 | C ObjC C++ ObjC++ | |
a7b2e184 | 1445 | Emit debug annotations during preprocessing. |
847e697a | 1446 | |
5f5babf1 | 1447 | fdeduce-init-list |
15694fdd | 1448 | C++ ObjC++ Var(flag_deduce_init_list) Init(0) |
a7b2e184 | 1449 | -fdeduce-init-list enable deduction of std::initializer_list for a template type parameter from a brace-enclosed initializer-list. |
5f5babf1 | 1450 | |
1f26ac87 JM |
1451 | fdeclone-ctor-dtor |
1452 | C++ ObjC++ Var(flag_declone_ctor_dtor) Init(-1) | |
a7b2e184 | 1453 | Factor complex constructors and destructors to favor space over speed. |
1f26ac87 | 1454 | |
fef3106c | 1455 | fdefault-inline |
2d2bd949 | 1456 | C++ ObjC++ Ignore |
5498f011 | 1457 | Does nothing. Preserved for backward compatibility. |
fef3106c | 1458 | |
f012c8ef DM |
1459 | fdiagnostics-show-template-tree |
1460 | C++ ObjC++ Var(flag_diagnostics_show_template_tree) Init(0) | |
1461 | Print hierarchical comparisons when template types are mismatched. | |
1462 | ||
ccfc4c91 OW |
1463 | fdirectives-only |
1464 | C ObjC C++ ObjC++ | |
1465 | Preprocess directives only. | |
1466 | ||
fef3106c NB |
1467 | fdollars-in-identifiers |
1468 | C ObjC C++ ObjC++ | |
a7b2e184 | 1469 | Permit '$' as an identifier character. |
fef3106c | 1470 | |
7365279f BK |
1471 | fmacro-prefix-map= |
1472 | C ObjC C++ ObjC++ Joined RejectNegative | |
1473 | -fmacro-prefix-map=<old>=<new> Map one directory name to another in __FILE__, __BASE_FILE__, and __builtin_FILE(). | |
1474 | ||
3b78de56 AC |
1475 | fdump-ada-spec |
1476 | C ObjC C++ ObjC++ RejectNegative Var(flag_dump_ada_spec) | |
a7b2e184 | 1477 | Write all declarations as Ada code transitively. |
3b78de56 AC |
1478 | |
1479 | fdump-ada-spec-slim | |
1480 | C ObjC C++ ObjC++ RejectNegative Var(flag_dump_ada_spec_slim) | |
a7b2e184 | 1481 | Write all declarations as Ada code for the given file only. |
3b78de56 | 1482 | |
fef3106c | 1483 | felide-constructors |
5498f011 | 1484 | C++ ObjC++ Var(flag_elide_constructors) Init(1) |
fef3106c | 1485 | |
f012c8ef DM |
1486 | felide-type |
1487 | C++ ObjC++ Var(flag_elide_type) Init(1) | |
1488 | -fno-elide-type Do not elide common elements in template comparisons. | |
1489 | ||
fef3106c | 1490 | fenforce-eh-specs |
5498f011 | 1491 | C++ ObjC++ Var(flag_enforce_eh_specs) Init(1) |
a7b2e184 | 1492 | Generate code to check exception specifications. |
fef3106c NB |
1493 | |
1494 | fenum-int-equiv | |
c0c12356 | 1495 | C++ ObjC++ Deprecated |
fef3106c | 1496 | |
e6cc3a24 ZW |
1497 | fexec-charset= |
1498 | C ObjC C++ ObjC++ Joined RejectNegative | |
a7b2e184 | 1499 | -fexec-charset=<cset> Convert all strings and character constants to character set <cset>. |
e6cc3a24 | 1500 | |
af15a2fe JM |
1501 | fextended-identifiers |
1502 | C ObjC C++ ObjC++ | |
a7b2e184 | 1503 | Permit universal character names (\\u and \\U) in identifiers. |
af15a2fe | 1504 | |
16dd5cfe EC |
1505 | finput-charset= |
1506 | C ObjC C++ ObjC++ Joined RejectNegative | |
a7b2e184 | 1507 | -finput-charset=<cset> Specify the default character set for source files. |
16dd5cfe | 1508 | |
5af057d8 JM |
1509 | fextern-tls-init |
1510 | C++ ObjC++ Var(flag_extern_tls_init) Init(-1) | |
a7b2e184 | 1511 | Support dynamic initialization of thread-local variables in a different translation unit. |
16dd5cfe | 1512 | |
fef3106c | 1513 | fexternal-templates |
c0c12356 | 1514 | C++ ObjC++ Deprecated |
fef3106c | 1515 | |
fef3106c | 1516 | ffor-scope |
c0c12356 | 1517 | C++ ObjC++ Deprecated |
fef3106c NB |
1518 | |
1519 | ffreestanding | |
820b51ae | 1520 | C ObjC C++ ObjC++ |
a7b2e184 | 1521 | Do not assume that standard C libraries and \"main\" exist. |
fef3106c NB |
1522 | |
1523 | fgnu-keywords | |
5498f011 | 1524 | C++ ObjC++ Var(flag_no_gnu_keywords, 0) |
a7b2e184 | 1525 | Recognize GNU-defined keywords. |
fef3106c NB |
1526 | |
1527 | fgnu-runtime | |
fb5610fb | 1528 | ObjC ObjC++ LTO Report RejectNegative Var(flag_next_runtime,0) Init(NEXT_OBJC_RUNTIME) |
a7b2e184 | 1529 | Generate code for GNU runtime environment. |
fef3106c | 1530 | |
da1c7394 | 1531 | fgnu89-inline |
2cbac420 | 1532 | C ObjC Var(flag_gnu89_inline) Init(-1) |
a7b2e184 | 1533 | Use traditional GNU semantics for inline functions. |
da1c7394 | 1534 | |
fef3106c | 1535 | fguiding-decls |
c0c12356 | 1536 | C++ ObjC++ Deprecated |
fef3106c NB |
1537 | |
1538 | fhandle-exceptions | |
63b8a166 | 1539 | C++ ObjC++ Optimization Alias(fexceptions) Warn({%<-fhandle-exceptions%> has been renamed %<-fexceptions%> (and is now on by default)}) |
fef3106c NB |
1540 | |
1541 | fhonor-std | |
c0c12356 | 1542 | C++ ObjC++ Deprecated |
fef3106c NB |
1543 | |
1544 | fhosted | |
1545 | C ObjC | |
a7b2e184 | 1546 | Assume normal C execution environment. |
fef3106c NB |
1547 | |
1548 | fhuge-objects | |
c0c12356 | 1549 | C++ ObjC++ Deprecated |
a7b2e184 | 1550 | No longer supported. |
fef3106c NB |
1551 | |
1552 | fimplement-inlines | |
5498f011 | 1553 | C++ ObjC++ Var(flag_implement_inlines) Init(1) |
a7b2e184 | 1554 | Export functions even if they can be inlined. |
fef3106c NB |
1555 | |
1556 | fimplicit-inline-templates | |
5498f011 | 1557 | C++ ObjC++ Var(flag_implicit_inline_templates) Init(1) |
a7b2e184 | 1558 | Emit implicit instantiations of inline templates. |
fef3106c NB |
1559 | |
1560 | fimplicit-templates | |
5498f011 | 1561 | C++ ObjC++ Var(flag_implicit_templates) Init(1) |
a7b2e184 | 1562 | Emit implicit instantiations of templates. |
fef3106c | 1563 | |
31f7f784 JM |
1564 | fnew-inheriting-ctors |
1565 | C++ ObjC++ Var(flag_new_inheriting_ctors) Init(1) | |
1566 | Implement C++17 inheriting constructor semantics. | |
1567 | ||
d63d5d0c | 1568 | ffriend-injection |
c0c12356 | 1569 | C++ ObjC++ Deprecated |
d63d5d0c | 1570 | |
47ea1edf DK |
1571 | fkeep-inline-dllexport |
1572 | C C++ ObjC ObjC++ Var(flag_keep_inline_dllexport) Init(1) Report Condition(TARGET_DLLIMPORT_DECL_ATTRIBUTES) | |
a7b2e184 | 1573 | Don't emit dllexported inline functions unless needed. |
47ea1edf | 1574 | |
fef3106c | 1575 | flabels-ok |
c0c12356 | 1576 | C++ ObjC++ Deprecated |
fef3106c | 1577 | |
00c8e9f6 | 1578 | flax-vector-conversions |
5498f011 | 1579 | C ObjC C++ ObjC++ Var(flag_lax_vector_conversions) |
00c8e9f6 MS |
1580 | Allow implicit conversions between vectors with differing numbers of subparts and/or differing element types. |
1581 | ||
1c6ffbab QZ |
1582 | fmax-include-depth= |
1583 | C ObjC C++ ObjC++ Joined RejectNegative UInteger | |
1584 | fmax-include-depth=<number> Set the maximum depth of the nested #include. | |
1585 | ||
fef3106c | 1586 | fms-extensions |
5498f011 | 1587 | C ObjC C++ ObjC++ Var(flag_ms_extensions) |
a7b2e184 | 1588 | Don't warn about uses of Microsoft extensions. |
fef3106c | 1589 | |
5720c0dc | 1590 | fmudflap |
c0c12356 | 1591 | C ObjC C++ ObjC++ Deprecated |
5720c0dc RG |
1592 | |
1593 | fmudflapth | |
c0c12356 | 1594 | C ObjC C++ ObjC++ Deprecated |
5720c0dc RG |
1595 | |
1596 | fmudflapir | |
c0c12356 | 1597 | C ObjC C++ ObjC++ Deprecated |
5720c0dc | 1598 | |
fef3106c | 1599 | fname-mangling-version- |
c0c12356 | 1600 | C++ ObjC++ Joined Deprecated |
fef3106c NB |
1601 | |
1602 | fnew-abi | |
c0c12356 | 1603 | C++ ObjC++ Deprecated |
fef3106c | 1604 | |
31bfc9b9 JM |
1605 | fnew-ttp-matching |
1606 | C++ ObjC++ Var(flag_new_ttp) | |
1607 | Implement resolution of DR 150 for matching of template template arguments. | |
1608 | ||
fef3106c | 1609 | fnext-runtime |
fb5610fb | 1610 | ObjC ObjC++ LTO Report RejectNegative Var(flag_next_runtime) |
a7b2e184 | 1611 | Generate code for NeXT (Apple Mac OS X) runtime environment. |
264fa2db ZL |
1612 | |
1613 | fnil-receivers | |
5498f011 | 1614 | ObjC ObjC++ Var(flag_nil_receivers) Init(1) |
a7b2e184 | 1615 | Assume that receivers of Objective-C messages may be nil. |
fef3106c | 1616 | |
dcaaa5a0 DP |
1617 | flocal-ivars |
1618 | ObjC ObjC++ Var(flag_local_ivars) Init(1) | |
1619 | Allow access to instance variables as if they were local declarations within instance method implementations. | |
1620 | ||
1621 | fivar-visibility= | |
1622 | ObjC ObjC++ Joined RejectNegative Enum(ivar_visibility) Var(default_ivar_visibility) Init(IVAR_VISIBILITY_PROTECTED) | |
a7b2e184 | 1623 | -fvisibility=[private|protected|public|package] Set the default symbol visibility. |
dcaaa5a0 DP |
1624 | |
1625 | Enum | |
1626 | Name(ivar_visibility) Type(enum ivar_visibility) UnknownError(unrecognized ivar visibility value %qs) | |
1627 | ||
1628 | EnumValue | |
1629 | Enum(ivar_visibility) String(private) Value(IVAR_VISIBILITY_PRIVATE) | |
1630 | ||
1631 | EnumValue | |
1632 | Enum(ivar_visibility) String(protected) Value(IVAR_VISIBILITY_PROTECTED) | |
1633 | ||
1634 | EnumValue | |
1635 | Enum(ivar_visibility) String(public) Value(IVAR_VISIBILITY_PUBLIC) | |
1636 | ||
1637 | EnumValue | |
1638 | Enum(ivar_visibility) String(package) Value(IVAR_VISIBILITY_PACKAGE) | |
1639 | ||
fef3106c | 1640 | fnonansi-builtins |
5498f011 | 1641 | C++ ObjC++ Var(flag_no_nonansi_builtin, 0) |
fef3106c NB |
1642 | |
1643 | fnonnull-objects | |
c0c12356 | 1644 | C++ ObjC++ Deprecated |
fef3106c | 1645 | |
9feb3d6a JM |
1646 | fnothrow-opt |
1647 | C++ ObjC++ Optimization Var(flag_nothrow_opt) | |
a7b2e184 | 1648 | Treat a throw() exception specification as noexcept to improve code size. |
9feb3d6a | 1649 | |
0a256240 | 1650 | fobjc-abi-version= |
fb5610fb | 1651 | ObjC ObjC++ LTO Joined Report RejectNegative UInteger Var(flag_objc_abi) |
0a256240 NP |
1652 | Specify which ABI to use for Objective-C family code and meta-data generation. |
1653 | ||
6e955430 ZL |
1654 | ; Generate special '- .cxx_construct' and '- .cxx_destruct' methods |
1655 | ; to initialize any non-POD ivars in Objective-C++ classes. | |
1656 | fobjc-call-cxx-cdtors | |
1657 | ObjC++ Var(flag_objc_call_cxx_cdtors) | |
a7b2e184 | 1658 | Generate special Objective-C methods to initialize/destroy non-POD C++ ivars, if needed. |
6e955430 ZL |
1659 | |
1660 | fobjc-direct-dispatch | |
1661 | ObjC ObjC++ Var(flag_objc_direct_dispatch) | |
a7b2e184 | 1662 | Allow fast jumps to the message dispatcher. |
6e955430 ZL |
1663 | |
1664 | ; Nonzero means that we will allow new ObjC exception syntax (@throw, | |
1665 | ; @try, etc.) in source code. | |
264fa2db | 1666 | fobjc-exceptions |
6e955430 | 1667 | ObjC ObjC++ Var(flag_objc_exceptions) |
a7b2e184 | 1668 | Enable Objective-C exception and synchronization syntax. |
264fa2db | 1669 | |
6e955430 | 1670 | fobjc-gc |
fb5610fb | 1671 | ObjC ObjC++ LTO Var(flag_objc_gc) |
a7b2e184 | 1672 | Enable garbage collection (GC) in Objective-C/Objective-C++ programs. |
6e955430 | 1673 | |
0a256240 NP |
1674 | fobjc-nilcheck |
1675 | ObjC ObjC++ Var(flag_objc_nilcheck,1) | |
1676 | Enable inline checks for nil receivers with the NeXT runtime and ABI version 2. | |
1677 | ||
6e955430 | 1678 | ; Nonzero means that we generate NeXT setjmp based exceptions. |
093c7153 | 1679 | fobjc-sjlj-exceptions |
6e955430 | 1680 | ObjC ObjC++ Var(flag_objc_sjlj_exceptions) Init(-1) |
a7b2e184 | 1681 | Enable Objective-C setjmp exception handling runtime. |
093c7153 | 1682 | |
22d8d616 NP |
1683 | fobjc-std=objc1 |
1684 | ObjC ObjC++ Var(flag_objc1_only) | |
a7b2e184 | 1685 | Conform to the Objective-C 1.0 language as implemented in GCC 4.0. |
22d8d616 | 1686 | |
41dbbb37 | 1687 | fopenacc |
a0c88d06 | 1688 | C ObjC C++ ObjC++ LTO Var(flag_openacc) |
a7b2e184 | 1689 | Enable OpenACC. |
41dbbb37 | 1690 | |
b6adbb9f NS |
1691 | fopenacc-dim= |
1692 | C ObjC C++ ObjC++ LTO Joined Var(flag_openacc_dims) | |
1693 | Specify default OpenACC compute dimensions. | |
1694 | ||
953ff289 | 1695 | fopenmp |
1506ae0e | 1696 | C ObjC C++ ObjC++ LTO Var(flag_openmp) |
a7b2e184 | 1697 | Enable OpenMP (implies -frecursive in Fortran). |
953ff289 | 1698 | |
6d7f7e0a TB |
1699 | fopenmp-simd |
1700 | C ObjC C++ ObjC++ Var(flag_openmp_simd) | |
a7b2e184 | 1701 | Enable OpenMP's SIMD directives. |
6d7f7e0a | 1702 | |
fef3106c NB |
1703 | foperator-names |
1704 | C++ ObjC++ | |
a7b2e184 | 1705 | Recognize C++ keywords like \"compl\" and \"xor\". |
fef3106c NB |
1706 | |
1707 | foptional-diags | |
2d2bd949 | 1708 | C++ ObjC++ Ignore |
5498f011 | 1709 | Does nothing. Preserved for backward compatibility. |
fef3106c NB |
1710 | |
1711 | fpch-deps | |
1712 | C ObjC C++ ObjC++ | |
1713 | ||
c0d578e6 GK |
1714 | fpch-preprocess |
1715 | C ObjC C++ ObjC++ | |
a7b2e184 | 1716 | Look for and use PCH files even when preprocessing. |
c0d578e6 | 1717 | |
fef3106c | 1718 | fpermissive |
0c3641b0 | 1719 | C++ ObjC++ Var(flag_permissive) |
a7b2e184 | 1720 | Downgrade conformance errors to warnings. |
fef3106c | 1721 | |
478a1c5b ILT |
1722 | fplan9-extensions |
1723 | C ObjC Var(flag_plan9_extensions) | |
a7b2e184 | 1724 | Enable Plan 9 language extensions. |
478a1c5b | 1725 | |
fef3106c NB |
1726 | fpreprocessed |
1727 | C ObjC C++ ObjC++ | |
a7b2e184 | 1728 | Treat the input file as already preprocessed. |
fef3106c | 1729 | |
92582b75 TT |
1730 | ftrack-macro-expansion |
1731 | C ObjC C++ ObjC++ JoinedOrMissing RejectNegative UInteger | |
1732 | ; converted into ftrack-macro-expansion= | |
1733 | ||
1734 | ftrack-macro-expansion= | |
1735 | C ObjC C++ ObjC++ JoinedOrMissing RejectNegative UInteger | |
a7b2e184 | 1736 | -ftrack-macro-expansion=<0|1|2> Track locations of tokens coming from macro expansion and display them in error messages. |
92582b75 | 1737 | |
6ea2bd47 | 1738 | fpretty-templates |
5498f011 | 1739 | C++ ObjC++ Var(flag_pretty_templates) Init(1) |
a7b2e184 | 1740 | -fno-pretty-templates Do not pretty-print template specializations as the template signature followed by the arguments. |
6ea2bd47 | 1741 | |
88d0c3f0 | 1742 | fprintf-return-value |
89990732 | 1743 | C ObjC C++ ObjC++ LTO Optimization Var(flag_printf_return_value) Init(1) |
88d0c3f0 MS |
1744 | Treat known sprintf return values as constants. |
1745 | ||
264fa2db | 1746 | freplace-objc-classes |
fb5610fb | 1747 | ObjC ObjC++ LTO Var(flag_replace_objc_classes) |
a7b2e184 | 1748 | Used in Fix-and-Continue mode to indicate that object files may be swapped in at runtime. |
264fa2db | 1749 | |
fef3106c NB |
1750 | frepo |
1751 | C++ ObjC++ | |
a7b2e184 | 1752 | Enable automatic template instantiation. |
fef3106c NB |
1753 | |
1754 | frtti | |
5498f011 | 1755 | C++ ObjC++ Optimization Var(flag_rtti) Init(1) |
a7b2e184 | 1756 | Generate run time type descriptor information. |
fef3106c | 1757 | |
fef3106c | 1758 | fshort-enums |
dd6fe7d4 | 1759 | C ObjC C++ ObjC++ LTO Optimization Var(flag_short_enums) |
a7b2e184 | 1760 | Use the narrowest integer type possible for enumeration types. |
fef3106c NB |
1761 | |
1762 | fshort-wchar | |
dd6fe7d4 | 1763 | C ObjC C++ ObjC++ LTO Optimization Var(flag_short_wchar) |
a7b2e184 | 1764 | Force the underlying type for \"wchar_t\" to be \"unsigned short\". |
fef3106c | 1765 | |
fef3106c | 1766 | fsigned-bitfields |
5498f011 | 1767 | C ObjC C++ ObjC++ Var(flag_signed_bitfields) Init(1) |
a7b2e184 | 1768 | When \"signed\" or \"unsigned\" is not given make the bitfield signed. |
fef3106c NB |
1769 | |
1770 | fsigned-char | |
5498f011 | 1771 | C ObjC C++ ObjC++ LTO Var(flag_signed_char) |
a7b2e184 | 1772 | Make \"char\" signed by default. |
fef3106c | 1773 | |
20b06add JM |
1774 | fsized-deallocation |
1775 | C++ ObjC++ Var(flag_sized_deallocation) Init(-1) | |
a7b2e184 | 1776 | Enable C++14 sized deallocation support. |
20b06add | 1777 | |
fef3106c | 1778 | fsquangle |
c0c12356 | 1779 | C++ ObjC++ Deprecated |
fef3106c | 1780 | |
ee45a32d | 1781 | fsso-struct= |
fc73e60c | 1782 | C ObjC Joined RejectNegative Enum(sso_struct) Var(default_sso) Init(SSO_NATIVE) |
4e89adf9 | 1783 | -fsso-struct=[big-endian|little-endian|native] Set the default scalar storage order. |
ee45a32d EB |
1784 | |
1785 | Enum | |
1786 | Name(sso_struct) Type(enum scalar_storage_order_kind) UnknownError(unrecognized scalar storage order value %qs) | |
1787 | ||
1788 | EnumValue | |
1789 | Enum(sso_struct) String(big-endian) Value(SSO_BIG_ENDIAN) | |
1790 | ||
1791 | EnumValue | |
1792 | Enum(sso_struct) String(little-endian) Value(SSO_LITTLE_ENDIAN) | |
1793 | ||
4e89adf9 EB |
1794 | EnumValue |
1795 | Enum(sso_struct) String(native) Value(SSO_NATIVE) | |
1796 | ||
fef3106c | 1797 | fstats |
5498f011 | 1798 | C++ ObjC++ Var(flag_detailed_statistics) |
a7b2e184 | 1799 | Display statistics accumulated during compilation. |
fef3106c | 1800 | |
cbb4feb3 JM |
1801 | fstrict-enums |
1802 | C++ ObjC++ Optimization Var(flag_strict_enums) | |
a7b2e184 | 1803 | Assume that values of enumeration type are always within the minimum range of that type. |
cbb4feb3 | 1804 | |
fef3106c | 1805 | fstrict-prototype |
c0c12356 | 1806 | C++ ObjC++ Deprecated |
fef3106c | 1807 | |
d0cf395a JM |
1808 | fstrong-eval-order |
1809 | C++ ObjC++ Common Alias(fstrong-eval-order=, all, none) | |
1810 | Follow the C++17 evaluation order requirements for assignment expressions, | |
1811 | shift, member function calls, etc. | |
1812 | ||
1813 | fstrong-eval-order= | |
d4a6c0ea | 1814 | C++ ObjC++ Common Var(flag_strong_eval_order) Joined Enum(strong_eval_order) RejectNegative Init(-1) |
d0cf395a JM |
1815 | Follow the C++17 evaluation order requirements for assignment expressions, |
1816 | shift, member function calls, etc. | |
1817 | ||
1818 | Enum | |
1819 | Name(strong_eval_order) Type(int) | |
1820 | ||
1821 | EnumValue | |
1822 | Enum(strong_eval_order) String(none) Value(0) | |
1823 | ||
1824 | EnumValue | |
1825 | Enum(strong_eval_order) String(some) Value(1) | |
1826 | ||
1827 | EnumValue | |
1828 | Enum(strong_eval_order) String(all) Value(2) | |
1829 | ||
fef3106c | 1830 | ftabstop= |
7b086b11 | 1831 | C ObjC C++ ObjC++ Joined RejectNegative UInteger |
a7b2e184 | 1832 | -ftabstop=<number> Distance between tab stops for column reporting. |
fef3106c | 1833 | |
a12bf402 MLI |
1834 | ftemplate-backtrace-limit= |
1835 | C++ ObjC++ Joined RejectNegative UInteger Var(template_backtrace_limit) Init(10) | |
a7b2e184 | 1836 | Set the maximum number of template instantiation notes for a single warning or error. |
a12bf402 | 1837 | |
fef3106c | 1838 | ftemplate-depth- |
5de8299c | 1839 | C++ ObjC++ Joined RejectNegative Undocumented Alias(ftemplate-depth=) |
124e0d27 MLI |
1840 | |
1841 | ftemplate-depth= | |
c22cacf3 | 1842 | C++ ObjC++ Joined RejectNegative UInteger |
a7b2e184 | 1843 | -ftemplate-depth=<number> Specify maximum template instantiation depth. |
fef3106c NB |
1844 | |
1845 | fthis-is-variable | |
c0c12356 | 1846 | C++ ObjC++ Deprecated |
fef3106c | 1847 | |
40aac948 | 1848 | fthreadsafe-statics |
5498f011 | 1849 | C++ ObjC++ Optimization Var(flag_threadsafe_statics) Init(1) |
a7b2e184 | 1850 | -fno-threadsafe-statics Do not generate thread-safe code for initializing local statics. |
40aac948 | 1851 | |
fef3106c | 1852 | funsigned-bitfields |
f0036cca | 1853 | C ObjC C++ ObjC++ Var(flag_signed_bitfields, 0) |
a7b2e184 | 1854 | When \"signed\" or \"unsigned\" is not given make the bitfield unsigned. |
fef3106c NB |
1855 | |
1856 | funsigned-char | |
f0036cca | 1857 | C ObjC C++ ObjC++ LTO Var(flag_signed_char, 0) |
a7b2e184 | 1858 | Make \"char\" unsigned by default. |
fef3106c NB |
1859 | |
1860 | fuse-cxa-atexit | |
5498f011 | 1861 | C++ ObjC++ Var(flag_use_cxa_atexit) Init(DEFAULT_USE_CXA_ATEXIT) |
a7b2e184 | 1862 | Use __cxa_atexit to register destructors. |
fef3106c | 1863 | |
c7b5e395 | 1864 | fuse-cxa-get-exception-ptr |
5498f011 | 1865 | C++ ObjC++ Var(flag_use_cxa_get_exception_ptr) Init(2) |
a7b2e184 | 1866 | Use __cxa_get_exception_ptr in exception handling. |
c7b5e395 | 1867 | |
d7afec4b | 1868 | fvisibility-inlines-hidden |
d0b07283 | 1869 | C++ ObjC++ |
a7b2e184 | 1870 | Marks all inlined functions and methods as having hidden visibility. |
d7afec4b | 1871 | |
ddbfd28d GK |
1872 | fvisibility-ms-compat |
1873 | C++ ObjC++ Var(flag_visibility_ms_compat) | |
a7b2e184 | 1874 | Changes visibility to match Microsoft Visual Studio by default. |
ddbfd28d | 1875 | |
fef3106c | 1876 | fvtable-gc |
c0c12356 | 1877 | C++ ObjC++ Deprecated |
a7b2e184 | 1878 | No longer supported. |
fef3106c NB |
1879 | |
1880 | fvtable-thunks | |
c0c12356 | 1881 | C++ ObjC++ Deprecated |
a7b2e184 | 1882 | No longer supported. |
fef3106c NB |
1883 | |
1884 | fweak | |
5498f011 | 1885 | C++ ObjC++ Var(flag_weak) Init(1) |
a7b2e184 | 1886 | Emit common-like symbols as weak symbols. |
fef3106c | 1887 | |
e6cc3a24 ZW |
1888 | fwide-exec-charset= |
1889 | C ObjC C++ ObjC++ Joined RejectNegative | |
a7b2e184 | 1890 | -fwide-exec-charset=<cset> Convert all wide strings and character constants to character set <cset>. |
e6cc3a24 | 1891 | |
b20d9f0c | 1892 | fworking-directory |
5498f011 | 1893 | C ObjC C++ ObjC++ Var(flag_working_directory) Init(-1) |
a7b2e184 | 1894 | Generate a #line directive pointing at the current working directory. |
b20d9f0c | 1895 | |
fef3106c | 1896 | fxref |
c0c12356 | 1897 | C++ ObjC++ Deprecated |
a7b2e184 | 1898 | No longer supported. |
fef3106c | 1899 | |
264fa2db | 1900 | fzero-link |
5498f011 | 1901 | ObjC ObjC++ Var(flag_zero_link) |
a7b2e184 | 1902 | Generate lazy class lookup (via objc_getClass()) for use in Zero-Link mode. |
264fa2db | 1903 | |
fef3106c | 1904 | gen-decls |
9ed32e27 | 1905 | ObjC ObjC++ Driver Var(flag_gen_declaration) RejectNegative |
a7b2e184 | 1906 | Dump declarations to a .decl file. |
fef3106c | 1907 | |
39ef6592 LC |
1908 | femit-struct-debug-baseonly |
1909 | C ObjC C++ ObjC++ | |
a7b2e184 | 1910 | -femit-struct-debug-baseonly Aggressive reduced debug info for structs. |
39ef6592 LC |
1911 | |
1912 | femit-struct-debug-reduced | |
1913 | C ObjC C++ ObjC++ | |
a7b2e184 | 1914 | -femit-struct-debug-reduced Conservative reduced debug info for structs. |
39ef6592 LC |
1915 | |
1916 | femit-struct-debug-detailed= | |
1917 | C ObjC C++ ObjC++ Joined | |
a7b2e184 | 1918 | -femit-struct-debug-detailed=<spec-list> Detailed reduced debug info for structs. |
39ef6592 | 1919 | |
a4a0016d | 1920 | fext-numeric-literals |
dcb466ec | 1921 | C++ ObjC++ Var(flag_ext_numeric_literals) Init(1) |
a4a0016d ESR |
1922 | Interpret imaginary, fixed-point, or other gnu number suffix as the corresponding |
1923 | number literal rather than a user-defined number literal. | |
1924 | ||
fef3106c | 1925 | idirafter |
61ff2bdc | 1926 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 1927 | -idirafter <dir> Add <dir> to the end of the system include path. |
fef3106c NB |
1928 | |
1929 | imacros | |
61ff2bdc | 1930 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing filename after %qs) |
a7b2e184 | 1931 | -imacros <file> Accept definition of macros in <file>. |
fef3106c | 1932 | |
2b6dd222 JM |
1933 | imultilib |
1934 | C ObjC C++ ObjC++ Joined Separate | |
a7b2e184 | 1935 | -imultilib <dir> Set <dir> to be the multilib include subdirectory. |
2b6dd222 | 1936 | |
fef3106c | 1937 | include |
61ff2bdc | 1938 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing filename after %qs) |
a7b2e184 | 1939 | -include <file> Include the contents of <file> before other files. |
fef3106c NB |
1940 | |
1941 | iprefix | |
1942 | C ObjC C++ ObjC++ Joined Separate | |
a7b2e184 | 1943 | -iprefix <path> Specify <path> as a prefix for next two options. |
fef3106c NB |
1944 | |
1945 | isysroot | |
61ff2bdc | 1946 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 1947 | -isysroot <dir> Set <dir> to be the system root directory. |
fef3106c NB |
1948 | |
1949 | isystem | |
61ff2bdc | 1950 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 1951 | -isystem <dir> Add <dir> to the start of the system include path. |
fef3106c | 1952 | |
4bed3787 | 1953 | iquote |
61ff2bdc | 1954 | C ObjC C++ ObjC++ Joined Separate MissingArgError(missing path after %qs) |
a7b2e184 | 1955 | -iquote <dir> Add <dir> to the end of the quote include path. |
4bed3787 | 1956 | |
fef3106c NB |
1957 | iwithprefix |
1958 | C ObjC C++ ObjC++ Joined Separate | |
a7b2e184 | 1959 | -iwithprefix <dir> Add <dir> to the end of the system include path. |
fef3106c NB |
1960 | |
1961 | iwithprefixbefore | |
1962 | C ObjC C++ ObjC++ Joined Separate | |
a7b2e184 | 1963 | -iwithprefixbefore <dir> Add <dir> to the end of the main include path. |
fef3106c NB |
1964 | |
1965 | lang-asm | |
603349bf | 1966 | C Undocumented RejectDriver |
fef3106c | 1967 | |
e200444e JM |
1968 | no-integrated-cpp |
1969 | Driver | |
1970 | ||
fef3106c NB |
1971 | nostdinc |
1972 | C ObjC C++ ObjC++ | |
a7b2e184 | 1973 | Do not search standard system include directories (those specified with -isystem will still be used). |
fef3106c NB |
1974 | |
1975 | nostdinc++ | |
72de27ea | 1976 | C++ ObjC++ |
a7b2e184 | 1977 | Do not search standard system include directories for C++. |
fef3106c NB |
1978 | |
1979 | o | |
1980 | C ObjC C++ ObjC++ Joined Separate | |
72de27ea | 1981 | ; Documented in common.opt |
fef3106c NB |
1982 | |
1983 | pedantic | |
c1771a20 | 1984 | C ObjC C++ ObjC++ Alias(Wpedantic) |
72de27ea | 1985 | ; Documented in common.opt |
fef3106c | 1986 | |
fef3106c NB |
1987 | print-objc-runtime-info |
1988 | ObjC ObjC++ | |
a7b2e184 | 1989 | Generate C header of platform-specific features. |
fef3106c NB |
1990 | |
1991 | remap | |
1992 | C ObjC C++ ObjC++ | |
a7b2e184 | 1993 | Remap file names when including files. |
fef3106c NB |
1994 | |
1995 | std=c++98 | |
1996 | C++ ObjC++ | |
a7b2e184 | 1997 | Conform to the ISO 1998 C++ standard revised by the 2003 technical corrigendum. |
c7dc8804 JM |
1998 | |
1999 | std=c++03 | |
2000 | C++ ObjC++ Alias(std=c++98) | |
a7b2e184 | 2001 | Conform to the ISO 1998 C++ standard revised by the 2003 technical corrigendum. |
fef3106c | 2002 | |
97e3ad20 | 2003 | std=c++11 |
966541e3 | 2004 | C++ ObjC++ |
a7b2e184 | 2005 | Conform to the ISO 2011 C++ standard. |
97e3ad20 JM |
2006 | |
2007 | std=c++0x | |
70e24808 | 2008 | C++ ObjC++ Alias(std=c++11) Undocumented |
a7b2e184 | 2009 | Deprecated in favor of -std=c++11. |
966541e3 | 2010 | |
552b8185 | 2011 | std=c++1y |
028aee17 | 2012 | C++ ObjC++ Alias(std=c++14) Undocumented |
a7b2e184 | 2013 | Deprecated in favor of -std=c++14. |
70e24808 JM |
2014 | |
2015 | std=c++14 | |
381bf11e | 2016 | C++ ObjC++ |
a7b2e184 | 2017 | Conform to the ISO 2014 C++ standard. |
552b8185 | 2018 | |
da73100b | 2019 | std=c++1z |
7b936140 JJ |
2020 | C++ ObjC++ Alias(std=c++17) Undocumented |
2021 | Deprecated in favor of -std=c++17. | |
da73100b JM |
2022 | |
2023 | std=c++17 | |
7b936140 JJ |
2024 | C++ ObjC++ |
2025 | Conform to the ISO 2017 C++ standard. | |
da73100b | 2026 | |
026a79f7 AS |
2027 | std=c++2a |
2028 | C++ ObjC++ | |
2029 | Conform to the ISO 2020(?) C++ draft standard (experimental and incomplete support). | |
2030 | ||
48b0b196 | 2031 | std=c11 |
2778d766 | 2032 | C ObjC |
a7b2e184 | 2033 | Conform to the ISO 2011 C standard. |
48b0b196 JM |
2034 | |
2035 | std=c1x | |
2036 | C ObjC Alias(std=c11) | |
a7b2e184 | 2037 | Deprecated in favor of -std=c11. |
2778d766 | 2038 | |
c76dc9c3 JM |
2039 | std=c17 |
2040 | C ObjC | |
7a8a92c4 | 2041 | Conform to the ISO 2017 C standard (published in 2018). |
1e39313a JM |
2042 | |
2043 | std=c18 | |
2044 | C ObjC Alias(std=c17) | |
7a8a92c4 | 2045 | Conform to the ISO 2017 C standard (published in 2018). |
c76dc9c3 | 2046 | |
9f936c86 JM |
2047 | std=c2x |
2048 | C ObjC | |
2049 | Conform to the ISO 202X C standard draft (experimental and incomplete support). | |
2050 | ||
fef3106c | 2051 | std=c89 |
5de8299c | 2052 | C ObjC Alias(std=c90) |
a7b2e184 | 2053 | Conform to the ISO 1990 C standard. |
fef3106c | 2054 | |
7e1542b9 MLI |
2055 | std=c90 |
2056 | C ObjC | |
a7b2e184 | 2057 | Conform to the ISO 1990 C standard. |
7e1542b9 | 2058 | |
fef3106c NB |
2059 | std=c99 |
2060 | C ObjC | |
a7b2e184 | 2061 | Conform to the ISO 1999 C standard. |
fef3106c NB |
2062 | |
2063 | std=c9x | |
5de8299c | 2064 | C ObjC Alias(std=c99) |
a7b2e184 | 2065 | Deprecated in favor of -std=c99. |
fef3106c NB |
2066 | |
2067 | std=gnu++98 | |
2068 | C++ ObjC++ | |
97e3ad20 | 2069 | Conform to the ISO 1998 C++ standard revised by the 2003 technical |
a7b2e184 | 2070 | corrigendum with GNU extensions. |
fef3106c | 2071 | |
97e3ad20 JM |
2072 | std=gnu++03 |
2073 | C++ ObjC++ Alias(std=gnu++98) | |
2074 | Conform to the ISO 1998 C++ standard revised by the 2003 technical | |
a7b2e184 | 2075 | corrigendum with GNU extensions. |
97e3ad20 JM |
2076 | |
2077 | std=gnu++11 | |
966541e3 | 2078 | C++ ObjC++ |
a7b2e184 | 2079 | Conform to the ISO 2011 C++ standard with GNU extensions. |
97e3ad20 JM |
2080 | |
2081 | std=gnu++0x | |
381bf11e | 2082 | C++ ObjC++ Alias(std=gnu++11) Undocumented |
a7b2e184 | 2083 | Deprecated in favor of -std=gnu++11. |
966541e3 | 2084 | |
552b8185 | 2085 | std=gnu++1y |
028aee17 | 2086 | C++ ObjC++ Alias(std=gnu++14) Undocumented |
a7b2e184 | 2087 | Deprecated in favor of -std=gnu++14. |
552b8185 | 2088 | |
a07f6ed2 | 2089 | std=gnu++14 |
028aee17 | 2090 | C++ ObjC++ |
a7b2e184 | 2091 | Conform to the ISO 2014 C++ standard with GNU extensions. |
a07f6ed2 | 2092 | |
da73100b | 2093 | std=gnu++1z |
7b936140 JJ |
2094 | C++ ObjC++ Alias(std=gnu++17) Undocumented |
2095 | Deprecated in favor of -std=gnu++17. | |
da73100b JM |
2096 | |
2097 | std=gnu++17 | |
7b936140 JJ |
2098 | C++ ObjC++ |
2099 | Conform to the ISO 2017 C++ standard with GNU extensions. | |
da73100b | 2100 | |
026a79f7 AS |
2101 | std=gnu++2a |
2102 | C++ ObjC++ | |
2103 | Conform to the ISO 2020(?) C++ draft standard with GNU extensions (experimental and incomplete support). | |
2104 | ||
48b0b196 | 2105 | std=gnu11 |
2778d766 | 2106 | C ObjC |
a7b2e184 | 2107 | Conform to the ISO 2011 C standard with GNU extensions. |
48b0b196 JM |
2108 | |
2109 | std=gnu1x | |
2110 | C ObjC Alias(std=gnu11) | |
a7b2e184 | 2111 | Deprecated in favor of -std=gnu11. |
2778d766 | 2112 | |
c76dc9c3 JM |
2113 | std=gnu17 |
2114 | C ObjC | |
7a8a92c4 | 2115 | Conform to the ISO 2017 C standard (published in 2018) with GNU extensions. |
1e39313a JM |
2116 | |
2117 | std=gnu18 | |
2118 | C ObjC Alias(std=gnu17) | |
7a8a92c4 | 2119 | Conform to the ISO 2017 C standard (published in 2018) with GNU extensions. |
c76dc9c3 | 2120 | |
9f936c86 JM |
2121 | std=gnu2x |
2122 | C ObjC | |
2123 | Conform to the ISO 202X C standard draft with GNU extensions (experimental and incomplete support). | |
2124 | ||
fef3106c | 2125 | std=gnu89 |
5de8299c | 2126 | C ObjC Alias(std=gnu90) |
a7b2e184 | 2127 | Conform to the ISO 1990 C standard with GNU extensions. |
fef3106c | 2128 | |
7e1542b9 MLI |
2129 | std=gnu90 |
2130 | C ObjC | |
a7b2e184 | 2131 | Conform to the ISO 1990 C standard with GNU extensions. |
7e1542b9 | 2132 | |
fef3106c NB |
2133 | std=gnu99 |
2134 | C ObjC | |
a7b2e184 | 2135 | Conform to the ISO 1999 C standard with GNU extensions. |
fef3106c NB |
2136 | |
2137 | std=gnu9x | |
5de8299c | 2138 | C ObjC Alias(std=gnu99) |
a7b2e184 | 2139 | Deprecated in favor of -std=gnu99. |
fef3106c NB |
2140 | |
2141 | std=iso9899:1990 | |
5de8299c | 2142 | C ObjC Alias(std=c90) |
a7b2e184 | 2143 | Conform to the ISO 1990 C standard. |
fef3106c NB |
2144 | |
2145 | std=iso9899:199409 | |
2146 | C ObjC | |
a7b2e184 | 2147 | Conform to the ISO 1990 C standard as amended in 1994. |
fef3106c NB |
2148 | |
2149 | std=iso9899:1999 | |
5de8299c | 2150 | C ObjC Alias(std=c99) |
a7b2e184 | 2151 | Conform to the ISO 1999 C standard. |
fef3106c NB |
2152 | |
2153 | std=iso9899:199x | |
5de8299c | 2154 | C ObjC Alias(std=c99) |
a7b2e184 | 2155 | Deprecated in favor of -std=iso9899:1999. |
fef3106c | 2156 | |
48b0b196 JM |
2157 | std=iso9899:2011 |
2158 | C ObjC Alias(std=c11) | |
a7b2e184 | 2159 | Conform to the ISO 2011 C standard. |
48b0b196 | 2160 | |
c76dc9c3 JM |
2161 | std=iso9899:2017 |
2162 | C ObjC Alias(std=c17) | |
7a8a92c4 | 2163 | Conform to the ISO 2017 C standard (published in 2018). |
1e39313a JM |
2164 | |
2165 | std=iso9899:2018 | |
2166 | C ObjC Alias(std=c17) | |
7a8a92c4 | 2167 | Conform to the ISO 2017 C standard (published in 2018). |
c76dc9c3 | 2168 | |
e200444e JM |
2169 | traditional |
2170 | Driver | |
2171 | ||
fef3106c NB |
2172 | traditional-cpp |
2173 | C ObjC C++ ObjC++ | |
a7b2e184 | 2174 | Enable traditional preprocessing. |
fef3106c NB |
2175 | |
2176 | trigraphs | |
2177 | C ObjC C++ ObjC++ | |
a7b2e184 | 2178 | -trigraphs Support ISO C trigraphs. |
fef3106c NB |
2179 | |
2180 | undef | |
5498f011 | 2181 | C ObjC C++ ObjC++ Var(flag_undef) |
a7b2e184 | 2182 | Do not predefine system-specific and GCC-specific macros. |
fef3106c NB |
2183 | |
2184 | v | |
d5478783 JM |
2185 | C ObjC C++ ObjC++ |
2186 | ; Documented in common.opt | |
fef3106c NB |
2187 | |
2188 | w | |
2189 | C ObjC C++ ObjC++ | |
72de27ea | 2190 | ; Documented in common.opt |
e11a4ae5 NB |
2191 | |
2192 | ; This comment is to ensure we retain the blank line above. |