Does dmd's -i "include imported modules in the compilation" switch generate object files?
Jacob Carlborg
doob at me.com
Wed Nov 4 19:15:50 UTC 2020
On 2020-11-03 20:02, H. S. Teoh wrote:
> I believe -i behaves as though you manually typed the names of the
> source files on the command line. So it would do what the compiler
> would usually do in the latter case.
Yes, this is correct.
> AFAIK, that means it loads everything into memory and produces only a
> single object file for the final executable. Separate compilation only
> happens if you invoke the compiler separately for each source file or
> group of source files.
If the `-c` flag is passed, the compiler will produce one object file
for each source file. If the `-c` flag is **not** passed, it will
produce one executable and one single object file.
--
/Jacob Carlborg
More information about the Digitalmars-d-learn
mailing list