labath accepted this revision.
labath added a comment.
This revision is now accepted and ready to land.

I very much support getting rid of shared pointers, and for this is I am 
inclined to accept this. However, I don't think it was ever really intended to 
use the sorting order of the regex text as a disambiguating criterion for data 
formatters, and I don't think we should make a feature of it now -- it's just 
too weird and I doubt anybody will expect that.

Since it seems that there is a need for disambiguation (libc++ can be 
configured to have any name for the inline namespace, so there's no way to make 
its regex not match the libstdc++ one), I think we should just use the 
registration order to disambiguate. Then we just need to make sure the 
libstdc++ formatter is registered before the libc++ one, which should be both 
easy to achieve and understandable.

Since you've recently touched this code, how hard do you think it would be to 
exchange the std::map in FormattersContainer for a std::vector? Would you be 
willing to give that a try?


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D66398/new/

https://reviews.llvm.org/D66398



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

Reply via email to