digitalmars.D.bugs - [Issue 6248] New: HTOD leaves out const when translating C headers
- d-bugmail puremagic.com (26/26) Jul 04 2011 http://d.puremagic.com/issues/show_bug.cgi?id=6248
- d-bugmail puremagic.com (12/12) Jul 04 2011 http://d.puremagic.com/issues/show_bug.cgi?id=6248
- d-bugmail puremagic.com (12/12) Nov 02 2012 http://d.puremagic.com/issues/show_bug.cgi?id=6248
http://d.puremagic.com/issues/show_bug.cgi?id=6248 Summary: HTOD leaves out const when translating C headers Product: D Version: D2 Platform: Other OS/Version: Windows Status: NEW Severity: major Priority: P2 Component: htod AssignedTo: nobody puremagic.com ReportedBy: andrej.mitrovich gmail.com --- Comment #0 from Andrej Mitrovic <andrej.mitrovich gmail.com> 2011-07-04 18:43:50 PDT --- test.h: void foo(const char *str); $ htod -hc test.h test.d: /* Converted to D from test.h by htod */ module test; extern (C): void foo(char *str); This is a big problem because now this function can't be passed a string via toStringz, or even a string literal which is implicitly zero-terminated. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jul 04 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6248 yebblies <yebblies gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |yebblies gmail.com --- Comment #1 from yebblies <yebblies gmail.com> 2011-07-05 12:45:43 EST --- This is because there is only one version of htod, for D1 and D2, and D1 does not have const. I think the fix would be for htod to emit 'in' instead of const in C function prototypes. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jul 04 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6248 Andrej Mitrovic <andrej.mitrovich gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WONTFIX --- Comment #2 from Andrej Mitrovic <andrej.mitrovich gmail.com> 2012-11-02 06:04:03 PDT --- We have better (cross-platform) tools for .h conversion, not gonna wait for Walter. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Nov 02 2012