> DMD without any flags produce enough debug info to see global > variable. > I reproduce this problem: only dmd with flag -g have it. > Without this flag or with -gc gdb show correct value. Thanks, -gc works indeed.