On errno

Luigi Rizzo rizzo at iet.unipi.it
Mon Mar 30 23:44:55 PDT 2009

On Tue, Mar 31, 2009 at 05:22:21AM +0000, Poul-Henning Kamp wrote:
> In message <49D1492C.5050101 at freebsd.org>, Tim Kientzle writes:
> >> The probelm with an integer is that you cannot give details
> >> like:
> >> 	"partition 3 overlaps bootcode"
> >> without precreating the N^2 possible messages of that kind.
> >
> >The standard solution if you need variable parameters,
> >of course, is to pass the parameters back:
> >    char *default_text: "partition %1d overlaps bootcode"
> >    arg1: 3
> And the "standard" solution is stupid and useless, because more
> often than not, some language, typically french, will want the
> arguments in the opposite order...

we are probably digressing but printf in glibc has specifiers to
indicate which argument you want to use for each format.


I suppose this takes an extra pass over the format string to collect
the proper type info for all arguments, so it is not
not a dramatic change in the implementation of *printf.


More information about the freebsd-arch mailing list