[Lldb-commits] [PATCH] D50071: Use rich mangling information in Symtab::InitNameIndexes()
Pavel Labath via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Tue Aug 7 12:48:33 PDT 2018
labath added inline comments.
Comment at: source/Core/RichManglingContext.cpp:133
+ case PluginCxxLanguage:
+ m_cxx_method_str = ConstString(
I thought we were going to get rid of this ConstString? The C++ plugin is able to provide the same (in fact, even stronger) lifetime guarantees as the IPD, so we could just have a single method that always returns a StringRef. (If you really want to, you can also have a ConstString-returning helper function, but it could be implemented the same way as it is now for IPD, so that both versions have the same runtime complexity.
I'd suggest having just a m_buffer StringRef object, which you set both here and in processIPDStrResult. Then `GetBufferRef()` can just return that object without any branching involved.
More information about the lldb-commits