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
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
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.
29 -print-missing-file-dependencies
38 D NoDriverArg Separate Alias(MD)
41 -write-user-dependencies
42 D NoDriverArg Separate Alias(MMD)
47 ; Different from documented use in C.
51 -Hd <dir> Write D interface files to directory <dir>.
55 -Hf <file> Write D interface to <file>.
63 ; Different from documented use in Fortran.
70 D Separate NoDriverArg
86 D Separate NoDriverArg
102 D Warning Var(warn_address)
117 Wno-alloca-larger-than
122 D Warning Var(warn_cast_result)
123 Warn about casts that will produce a null result.
131 ; Documented in common.opt
139 Warn from speculative compiles such as __traits(compiles).
146 D LangEnabledBy(D, Wall)
155 -Xf <file> Write JSON output to the given <file>.
159 Debug library to use instead of phobos.
163 Default library to use instead of phobos.
170 Generate code for all template instantiations.
174 Generate code for assert contracts.
178 ; Documented in common.opt
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.
185 Name(bounds_check) Type(int) UnknownError(unknown array bounds setting %qs)
188 Enum(bounds_check) String(off) Value(0)
191 Enum(bounds_check) String(safeonly) Value(1)
194 Enum(bounds_check) String(on) Value(2)
197 D Var(flag_no_builtin, 0)
202 Compile in debug code.
205 D Joined RejectNegative
206 -fdebug=<level|ident> Compile in debug code, code <= <level>, or code identified by <ident>.
210 Generate documentation.
213 D Joined RejectNegative
214 -fdoc-dir=<dir> Write documentation file to directory <dir>.
217 D Joined RejectNegative
218 -fdoc-file=<file> Write documentation to <file>.
221 D Joined RejectNegative
222 -fdoc-inc=<file> Include a Ddoc macro <file>.
226 Display the frontend AST after parsing and semantic passes.
228 fignore-unknown-pragmas
230 Ignore unsupported pragmas.
233 D Var(flag_invariants)
234 Generate code for class invariant contracts.
238 Generate a default D main() function when compiling.
241 D Joined RejectNegative
242 -fmodule-file=<package.module>=<filespec> use <filespec> as source file for <package.module>.
246 Generate ModuleInfo struct for output module.
249 D Joined RejectNegative
250 Process all modules specified on the command line, but only generate code for the module specified by the argument.
253 D Var(flag_postconditions)
254 Generate code for postcondition contracts.
257 D Var(flag_preconditions)
258 Generate code for precondition contracts.
262 Compile release version.
265 D Var(flag_switch_errors)
266 Generate code for switches without a default case.
270 List information on all language changes.
272 ftransition=checkimports
274 Give deprecation messages about -ftransition=import anomalies.
278 List all usages of complex or imaginary types.
282 Implement DIP1000: Scoped pointers (experimental).
286 Implement DIP25: Sealed references (experimental).
290 List all non-mutable fields which occupy an object instance.
294 Revert to single phase name lookup.
298 List all hidden GC allocations.
302 List all variables going into thread local storage.
306 Compile in unittest code.
309 D Joined RejectNegative
310 -fversion=<level|ident> Compile in version code >= <level> or identified by <ident>.
313 D Var(flag_weak) Init(1)
314 Emit common-like symbols as weak symbols.
334 Do not link the standard D library in the compilation.
342 Link the standard D library statically in the compilation.
346 Link the standard D library dynamically in the compilation.