[Issue 6232] And idea for std.string.toStringz docs
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Jun 30 17:32:00 PDT 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6232
Jonathan M Davis <jmdavisProg at gmx.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jmdavisProg at gmx.com
--- Comment #1 from Jonathan M Davis <jmdavisProg at gmx.com> 2011-06-30 17:27:01 PDT ---
That's a lot to add to the documentation for something which is completely
unnecessary to use or understand the function. And it would only make sense if
it were considered best practice to do this, and I think that you're going to
have a hard time convincing people that they should do this in the general
case. The typical thing to do with toStringz is to just pass the result
directly to a C function and be done with it. Your suggestion is completely
overkill in such cases.
This is an enhancement request, so I'm not going to just close it, but I really
don't think that anything like this should be in the documentation. A
function's documentation is for explaining what a function does and how its
used, not for stuff like this. This sort of thing would only make sense if
CcharPtr and tostringz2 were actually added to Phobos, in which case, the
documentation would go on _them_, not toStringz.
--
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