debugging in vs code on Windows
piotrklos
poliklosio at happypizza.com
Sat Oct 14 19:01:52 UTC 2017
On Saturday, 14 October 2017 at 13:12:51 UTC, Jerry wrote:
> On Friday, 13 October 2017 at 12:55:09 UTC, piotrklos wrote:
>> (...)
>
> If you use generate a 32-bit binary using DMD, it generates it
> in a format that the C/C++ extension doesn't understand. You
> need to compile -m32mscoff or -m64, and you need to make sure
> the /DEBUG is passed to the linker, as I don't think dmd passes
> it that. You can do that by passing "-L/DEBUG" to DMD (when
> using -m32mscoff or -m64). There should be a .pdb file that
> gets generated, when you start the debugger it should say that
> symbols were loaded for the exe.
>
> I also can't say for certain if debug information is even
> generated for the unittests, so that might be something worth
> looking into to make sure it does.
I have added this to dub.json:
"dmd-flags":[
"-g", "-m64", "-L/DEBUG"
]
but I don't see a pdb file generated when I build. What am I
doing wrong?
More information about the Digitalmars-d-learn
mailing list