On May 23, 2014, at 1:46 PM, Kian-Tat Lim <[log in to unmask]> wrote:
> Bill,
>
>> The situation is different when writing something like:
>> LOG_WARN("This is a warning about data = %d. So you have been warned!") % data;
>> because operator% is outside the parentheses.
>
> But does it have to be? Can you move it inside?
This might be possible. However, if it is, we would lose some of the flexibility offered by the boost::format style interface. In particular, we would no longer be able to re-use formatters (I gave an example of this at the end of the email that started this thread). Of course, we can always introduce more macros, but I fear more macros = confusion and unused functionality.
With that said, if we can achieve optimal efficiency along with essential boost::format functionality, placing the operator%'s within the macro parentheses might be a good solution. I'll look into this.
>
> --
> Kian-Tat Lim, LSST Data Management, [log in to unmask]
>
> ########################################################################
> Use REPLY-ALL to reply to list
>
> To unsubscribe from the QSERV-L list, click the following link:
> https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=QSERV-L&A=1
########################################################################
Use REPLY-ALL to reply to list
To unsubscribe from the QSERV-L list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=QSERV-L&A=1
|