logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From drkm <darkman_s...@yahoo.fr>
Subject Re: The logging macros
Date Thu, 26 Aug 2004 20:45:46 GMT
FabijanicA@nucorsteel.com writes:

> If you are not willing to pay it at production runtime, you have a
> choices of wrapping your calls into #ifdefs or redefining LOG_DEBUG
> into nothing and have compile time control.

  Or best, IMHO, define your own macro like this :

    #if defined( NDEBUG )
    #  define MY_DISABLED_IN_REALASE_LOGGING_DEBUG( logger , msg )
    #else
    #  define MY_DISABLED_IN_REALASE_LOGGING_DEBUG( logger , msg ) \
           LOG4CXX_DEBUG( logger , msg )
    #endif

--drkm, en recherche d'un stageĀ : http://www.fgeorges.org/ipl/stage.html


Mime
View raw message