DrSergei wrote: > Thanks for the patch. I'm all in favour of de-duplicating the formatter code, > but I'd prefer it if we kept the individual SummaryProvider's per STL. > > I.e., the code that extracts the data and size from the type should live in > the individual STL files. But the code that then formats the strings can be > generic. > > Is that feasible? > > Note, copy-paste between the formatters is not actually a bad thing per-se, > imo. It's useful for them to be developed separately because layouts can > drastically change, and at that point a generic implementation may become > convoluted to maintain. Also not every developer has access to every STL. > Having them separate also means a developer can focus on the specific STL > they're worried about, without breaking it for other STLs. That being said, > the stuff that just prints the data can definitely be generic, as it's not > STL specific.
I added special function to access data and size fields for each stl. `GenericInitializerList` already have data access functions inside it, so I thought it is normal. https://github.com/llvm/llvm-project/pull/171854 _______________________________________________ lldb-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
