jingham added a comment.

I not infrequently have some non-trivial code in the "if (log)" block that 
gathers the information that I am then going to print, or loops over entities 
printing them.  Putting more complex code like that inside a macro looks awful 
and is hard to debug.  I don't think that argues for not using the macros in 
the case where you are logging a simple string, but it does argue for keeping 
the old way available.

Also, some extant log messages don't have file and function because they are 
making structured readable output and the function noise is just that, and 
makes the logs harder to read.  It's worse when constructing logs that span 
functions because you would have to work way too hard to line things up nicely. 
 If we're going to keep the old log mechanism around, that's okay, you can just 
continue to use that for these purposes.  Otherwise, you might want have 
decorated and non-decorated variants.


https://reviews.llvm.org/D27459



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to