Predefined Names in GCC C++, where are they _all_ documented
Nathan Sidwell
nathan@codesourcery.com
Tue Jan 11 16:04:00 GMT 2005
Paul E Condon wrote:
> I have a need for a way to have an object/class be aware of it own
> text name. I think I can do this with __FUNCTION__ , but if I could
> find an exhaustive list of predefineds maybe something else would
> be more appropriate. Where can I find such a list. Also, I need to
> know which of these are part of standard C++ and which are special
> to GCC.
__FUNCTION__ & __PRETTY_FUNCTION__ are gnu extensions
to C and C++ standards. Look in the extensions section of the GCC
manual. They provide information to a function (member or non-member).
They do not provide information to a class or object, but
perhaps they'll fulfil your need.
nathan
--
Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
nathan@codesourcery.com :: http://www.planetfall.pwp.blueyonder.co.uk
More information about the Gcc-help
mailing list