[Issue 3914] Struct as argument that fits in register has member accessed wrong
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Mar 11 12:51:39 PST 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3914
--- Comment #1 from Don <clugdbug at yahoo.com.au> 2010-03-11 12:51:37 PST ---
Here's a slightly reduced test case which doesn't require any compiler flags.
Not a regression, fails even on DMD0.165.
It's a problem with variadic function parameters and fastpar arguments.
------------
struct SS {
char a, b, c, d;
}
void show(char[] args...) {
assert(args[0]=='A');
assert(args[1]=='L');
assert(args[2]=='D');
assert(args[3]=='O');
}
void A( SS ss ) {
show( ss.a, ss.b, ss.c, ss.d );
}
void main(){
SS ss3;
ss3.a = 'A';
ss3.b = 'L';
ss3.c = 'D';
ss3.d = 'O';
A( ss3 );
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list