Logging and Exception.
A macro allows you to effortlessly capture __FILE__
, __LINE__
and __func__
. Oh sure you could write them manually each time, but frankly this is tedious and error prone (both __FILE__
and __func__
are C-string so you risk mixing them up).