|
Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript electronics |
D.gnu - [Issue 1523] New: struct literals not work with typedef
http://d.puremagic.com/issues/show_bug.cgi?id=1523 Summary: struct literals not work with typedef Product: DGCC aka GDC Version: 0.24 Platform: PC OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: glue layer AssignedTo: dvdfrdmn users.sf.net ReportedBy: pop.atry gmail.com struct BaseStruct { int n; char c; } typedef BaseStruct MyStruct; void myFunction(MyStruct) {} int main() { myFunction(MyStruct(0, 'x')); return 0; } *********************************************** $ gdc typedef_struct_literals.d typedef_struct_literals.d:11: function typedef_struct_literals.myFunction (MyStruct) does not match parameter types (BaseStruct ) typedef_struct_literals.d:11: Error: cannot implicitly convert expression (BaseStruct(0,'x')) of type BaseStruct to MyStruct -- Sep 20 2007
|