hintonda added a comment.

It's just an effort to make the code a bit more accessible, especially for new 
users (or ones not used to running find/grep).

Steve had suggested adding an option that took the entire message and matched 
it when it was produced.  However, that won't work very well since the message 
isn't actually produced until just before it is printed, which means the 
assert/backtrace isn't in the correctly location if the it's delayed.  That's 
why I chose to simply print just the enum name and index.

Adding `__FILE__`/`__LINE__` info would help identify the exact location (could 
be multiple for the same error message), but due to the way the code is 
structured it isn't really doable.

It might be kinda fun writing the script you suggest -- I'll look into it, but 
printing the enum in the first place for little or no cost seems a bit more 
elegant.


https://reviews.llvm.org/D35175



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

Reply via email to