Fix build on sparc64-linux-gnu.
[official-gcc.git] / gcc / d / lang.opt
bloba9ce059f52dd72cd8c94b9b17aebeb7687891399
1 ; lang.opt -- Options for the D front end.
2 ; Copyright (C) 2006-2018 Free Software Foundation, Inc.
4 ; GCC is free software; you can redistribute it and/or modify it under
5 ; the terms of the GNU General Public License as published by the Free
6 ; Software Foundation; either version 3, or (at your option) any later
7 ; version.
9 ; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
10 ; WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 ; FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
12 ; for more details.
14 ; You should have received a copy of the GNU General Public License
15 ; along with GCC; see the file COPYING3.  If not see
16 ; <http://www.gnu.org/licenses/>.
18 ; See the GCC internals manual for a description of this file's format.
20 ; Please try to keep this file in ASCII collating order.
22 Language
25 -dependencies
26 D Alias(M)
27 ; Documented in C
29 -print-missing-file-dependencies
30 D Alias(MG)
31 ; Documented in C
33 -user-dependencies
34 D Alias(MM)
35 ; Documented in C
37 -write-dependencies
38 D NoDriverArg Separate Alias(MD)
39 ; Documented in C
41 -write-user-dependencies
42 D NoDriverArg Separate Alias(MMD)
43 ; Documented in C
47 ; Different from documented use in C.
50 D Joined Separate
51 -Hd <dir>       Write D interface files to directory <dir>.
54 D Joined Separate
55 -Hf <file>      Write D interface to <file>.
58 D Joined Separate
59 ; Documented in C
62 D Joined Separate
63 ; Different from documented use in Fortran.
67 ; Documented in C
70 D Separate NoDriverArg
71 ; Documented in C
74 D Joined Separate
75 ; Documented in C
79 ; Documented in C
83 ; Documented in C
85 MMD
86 D Separate NoDriverArg
87 ; Documented in C
91 ; Documented in C
94 D Joined Separate
95 ; Documented in C
98 D Joined Separate
99 ; Documented in C
101 Waddress
102 D Warning Var(warn_address)
103 ; Documented in C
105 Wall
107 ; Documented in C
109 Walloca
111 ; Documented in C
113 Walloca-larger-than=
115 ; Documented in C
117 Wno-alloca-larger-than
119 ; Documented in C
121 Wcast-result
122 D Warning Var(warn_cast_result)
123 Warn about casts that will produce a null result.
125 Wdeprecated
127 ; Documented in C
129 Werror
131 ; Documented in common.opt
133 Wpsabi
135 ; Documented in C
137 Wspeculative
139 Warn from speculative compiles such as __traits(compiles).
141 Wtemplates
143 ; Documented in C
145 Wunknown-pragmas
146 D LangEnabledBy(D, Wall)
147 ; Documented in C
151 Generate JSON file.
154 D Joined Separate
155 -Xf <file>      Write JSON output to the given <file>.
157 debuglib=
158 Driver Joined
159 Debug library to use instead of phobos.
161 defaultlib=
162 Driver Joined
163 Default library to use instead of phobos.
165 -verbose
166 D Alias(v)
168 fall-instantiations
170 Generate code for all template instantiations.
172 fassert
173 D Var(flag_assert)
174 Generate code for assert contracts.
176 fbounds-check
178 ; Documented in common.opt
180 fbounds-check=
181 D Joined RejectNegative Enum(bounds_check) Var(flag_bounds_check)
182 -fbounds-check=[on|safeonly|off]        Turn array bounds checks on, in @safe code only, or off.
184 Enum
185 Name(bounds_check) Type(int) UnknownError(unknown array bounds setting %qs)
187 EnumValue
188 Enum(bounds_check) String(off) Value(0)
190 EnumValue
191 Enum(bounds_check) String(safeonly) Value(1)
193 EnumValue
194 Enum(bounds_check) String(on) Value(2)
196 fbuiltin
197 D Var(flag_no_builtin, 0)
198 ; Documented in C
200 fdebug
202 Compile in debug code.
204 fdebug=
205 D Joined RejectNegative
206 -fdebug=<level|ident>   Compile in debug code, code <= <level>, or code identified by <ident>.
208 fdoc
210 Generate documentation.
212 fdoc-dir=
213 D Joined RejectNegative
214 -fdoc-dir=<dir> Write documentation file to directory <dir>.
216 fdoc-file=
217 D Joined RejectNegative
218 -fdoc-file=<file>       Write documentation to <file>.
220 fdoc-inc=
221 D Joined RejectNegative
222 -fdoc-inc=<file>        Include a Ddoc macro <file>.
224 fdump-d-original
226 Display the frontend AST after parsing and semantic passes.
228 fignore-unknown-pragmas
230 Ignore unsupported pragmas.
232 finvariants
233 D Var(flag_invariants)
234 Generate code for class invariant contracts.
236 fmain
237 D RejectNegative
238 Generate a default D main() function when compiling.
240 fmodule-file=
241 D Joined RejectNegative
242 -fmodule-file=<package.module>=<filespec>       use <filespec> as source file for <package.module>.
244 fmoduleinfo
246 Generate ModuleInfo struct for output module.
248 fonly=
249 D Joined RejectNegative
250 Process all modules specified on the command line, but only generate code for the module specified by the argument.
252 fpostconditions
253 D Var(flag_postconditions)
254 Generate code for postcondition contracts.
256 fpreconditions
257 D Var(flag_preconditions)
258 Generate code for precondition contracts.
260 frelease
262 Compile release version.
264 fswitch-errors
265 D Var(flag_switch_errors)
266 Generate code for switches without a default case.
268 ftransition=all
269 D RejectNegative
270 List information on all language changes.
272 ftransition=checkimports
273 D RejectNegative
274 Give deprecation messages about -ftransition=import anomalies.
276 ftransition=complex
277 D RejectNegative
278 List all usages of complex or imaginary types.
280 ftransition=dip1000
281 D RejectNegative
282 Implement DIP1000: Scoped pointers (experimental).
284 ftransition=dip25
285 D RejectNegative
286 Implement DIP25: Sealed references (experimental).
288 ftransition=field
289 D RejectNegative
290 List all non-mutable fields which occupy an object instance.
292 ftransition=import
293 D RejectNegative
294 Revert to single phase name lookup.
296 ftransition=nogc
297 D RejectNegative
298 List all hidden GC allocations.
300 ftransition=tls
301 D RejectNegative
302 List all variables going into thread local storage.
304 funittest
306 Compile in unittest code.
308 fversion=
309 D Joined RejectNegative
310 -fversion=<level|ident> Compile in version code >= <level> or identified by <ident>.
312 fweak
313 D Var(flag_weak) Init(1)
314 Emit common-like symbols as weak symbols.
316 imultilib
317 D Joined Separate
318 ; Documented in C
320 iprefix
321 D Joined Separate
322 ; Documented in C
324 isysroot
325 D Joined Separate
326 ; Documented in C
328 isystem
329 D Joined Separate
330 ; Documented in C
332 nophoboslib
333 Driver
334 Do not link the standard D library in the compilation.
336 nostdinc
338 ; Documented in C
340 static-libphobos
341 Driver
342 Link the standard D library statically in the compilation.
344 shared-libphobos
345 Driver
346 Link the standard D library dynamically in the compilation.
350 ; Documented in C