I want to print lots of debug log prints in C++. Is there a built-in library that will allow me to turn on/off these prints without commenting them out as I do today (i.e., let the user use a -print_log
/-debug
flag)?
EDIT: third party loggers will be welcomed.
Please include a short example of how to do this.
C log() PrototypeThe log() function takes a single argument and returns a value of type float . It is defined in <math. h> header file. In order to find the log() of long double or float numbers, you can use the following prototype.
google glog is a good example
http://google-glog.googlecode.com/svn/trunk/doc/glog.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With