burner / bugzilla_migration_test

0 stars 0 forks source link

CodeView: parent-scope not set for nested functions #22

Open burner opened 16 years ago

burner commented 16 years ago

jascha reported this on 2007-12-02T07:38:10Z

Transfered from https://issues.dlang.org/show_bug.cgi?id=1708

CC List

Description

par should point to the entry of main.func


S_GPROC32 par=x00000000 end=x00000000 next=x00000000 len=x001f debsta=x0007 debend=x001b off=x0000 seg=x0000 proctyp=x1004 near _D4main4funcFkZk6nestedMFkZv segidx = 5 offset = 00a1, lcfd = ec12, fd = 1, td = 2, targdisp = x0000

import std.stdio; import std.string;

uint func(uint outer_param) { uint outer_var = 56789+outer_param;

void nested(uint nested_param)
{
    int nested_var = 1234+nested_param;
    outer_var += nested_var;
}

nested(outer_param*123);
return outer_var;

}

void main(string[] args) { writefln("%d", func(atoi(args[1]))); }