[Issue 14363] DMD should compile SDC test0165.d

2015-03-29 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 deadalnix changed: What|Removed |Added CC||deadal...@gmail.com --- Comment #6 from deadalni

[Issue 14363] DMD should compile SDC test0165.d

2015-03-29 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 --- Comment #5 from Shammah Chancellor --- I'm not sure about that part of SDC. I will investigate and see if deadalnix has some input here. --

[Issue 14363] DMD should compile SDC test0165.d

2015-03-29 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 --- Comment #4 from Kenji Hara --- Maybe SDC inserts a hidden field to access enclosing scope in each derived classes? void main() { uint x = 7; class A { int fieldA; auto foo() { return x; } } auto makeB(uint y) {

[Issue 14363] DMD should compile SDC test0165.d

2015-03-28 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 --- Comment #3 from Kenji Hara --- (In reply to Shammah Chancellor from comment #2) > Your code has a bug? > > return new B(5); > > Should be: > > return new B(); Yes. Sorry. > With that, your example compiles and works just fine on SDC. Hmm, i

[Issue 14363] DMD should compile SDC test0165.d

2015-03-28 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 --- Comment #2 from Shammah Chancellor --- Your code has a bug? return new B(5); Should be: return new B(); With that, your example compiles and works just fine on SDC. (In reply to Kenji Hara from comment #1) > I'm not sure why SDC accepts th

[Issue 14363] DMD should compile SDC test0165.d

2015-03-28 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 --- Comment #1 from Kenji Hara --- I'm not sure why SDC accepts the code. The following reduced case is correctly rejected by dmd, because ba.foo() won't work expectedly. Maybe SDC generates wrong code? void main() { uint x = 7; class A

[Issue 14363] DMD should compile SDC test0165.d

2015-03-28 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14363 ag0ae...@gmail.com changed: What|Removed |Added Keywords||rejects-valid CC|