D2 and gdb

vnm green_ at tut.by
Wed Jan 26 13:00:08 PST 2011


On 01/26/2011 12:28 AM, Steven Schveighoffer wrote:
> On Tue, 25 Jan 2011 15:44:59 -0500, vnm <green_ at tut.by> wrote:
>
>> Why gdb can't show line information and why it shows symbols in
>> mangled form ? Is this software issues or I'm doing something wrong ?
>> AFAIK, gdb 7.2 integrated some patch for D support (including symbols
>> demangling feature). This patch was D1 only ?
>
> I don't know anything about the symbol mangling, but the symbol of main
> is actually _Dmain. main() is the runtime's main which ends up calling
> your main function. I'm pretty sure gdb doesn't know this.
>
> Likely, the runtime is compiled without the debug flags, so you won't
> get any line info there.
>
> Try breaking on Dmain instead.
>
> -Steve

Steve, Robert, thanks for explanations about main/_Dmain.
Situation with symbols names demangling stays unclear to me...



More information about the Digitalmars-d-learn mailing list