Re: __FUNCTION__ and debug.

From: Francesco Chemolli <kinkie-ml@dont-contact.us>
Date: 05 Nov 2002 08:56:46 +0100

Adrian Chadd <adrian@squid-cache.org> writes:

> On Sat, Oct 26, 2002, Robert Collins wrote:
> > I'd like to introduce a new debug api:
> >
> > trace(section, level)(const char *format, ...);
> >
> > This will over time replace debug() as the primary debugging output
> > tool.
> >
> > trace will have the following semantics:
> > It will prepend the __FUNCTION__ macro to the format string:
> > ie "Can't lock foo" in somefunc() will output as
> > "somefunc: Can't lock foo".
> >
> > It won't enforce, but also won't support, embedded \n characters.
> >
> > Any objections or minor tweaks?

I have one. Replace section-numbers with macros having a descriptive
name. More verbose and clearer.

-- 
	kinkie (kinkie-ml [at] libero [dot] it)
	Random fortune, unrelated to the message:
He who foresees calamities suffers them twice over.
Received on Tue Nov 05 2002 - 00:56:03 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:18:37 MST