Re: std.format example not working

2011-01-29 Thread Lars T. Kyllingstad
On Fri, 28 Jan 2011 23:30:06 -0500, Akakima wrote:

 Firt, i would like to know if you are interested in receiving comments
 an bug reports for DMD V1.

D1 bugs are still fixed, so bug reports are welcome.

  http://d.puremagic.com/issues/

D1 has been declared stable, though, so there is usually no point in 
submitting enhancement requests for it.


 If yes, then the following example does not work:
 
 http://www.digitalmars.com/d/1.0/phobos/std_format.html
 
 import std.c.stdio;
 import std.format;
 void formattedPrint(...)
 {
   void putc(char c)  {fputc(c, stdout);} std.format.doFormat(putc,
   _arguments, _argptr);
 }
 
 
 declaring: void putc(dchar c) fixes the problem.

That's a bug in the documentation, please report. :)


 Also to a D newbee like me, _arguments and _argptr are confusing.
 
 _arginfo or _argtype is more significant. _argptr could be _arglist or
 _argvalue or _arguments
 
 Those names would be a better fit to the explanations given.

That, on the other hand, would be a breaking change, so it won't happen.

-Lars


Re: std.format example not working

2011-01-29 Thread Akakima

 D1 bugs are still fixed, so bug reports are welcome.

  http://d.puremagic.com/issues/

 That's a bug in the documentation, please report. :)


Ok. Will submit a report.


 D1 has been declared stable, though, so there is usually no point in
 submitting enhancement requests for it.


I think that D1 should receive more attention.




 Also to a D newbee like me, _arguments and _argptr are confusing.

 _arginfo or _argtype is more significant. _argptr could be _arglist or
 _argvalue or _arguments

 Those names would be a better fit to the explanations given.

 That, on the other hand, would be a breaking change, so it won't happen.

Does not have to be breaking.
You could define new names while keeping the old.

Thanks for your attention.




std.format example not working

2011-01-28 Thread Akakima
Firt, i would like to know if you are interested in receiving
comments an bug reports for DMD V1.

If yes, then the following example does not work:

http://www.digitalmars.com/d/1.0/phobos/std_format.html

import std.c.stdio;
import std.format;
void formattedPrint(...)
{
  void putc(char c)  {fputc(c, stdout);}
  std.format.doFormat(putc, _arguments, _argptr);
}


declaring: void putc(dchar c) fixes the problem.

Also to a D newbee like me, _arguments and _argptr are confusing.

_arginfo or _argtype is more significant.
_argptr could be _arglist or _argvalue or _arguments

Those names would be a better fit to the explanations given.

_