[Lldb-commits] [lldb] [lldb] add TemplateRange and NameQualifiersRange to DemangledNameInfo (PR #150999)
Charles Zablit via lldb-commits
lldb-commits at lists.llvm.org
Tue Jul 29 07:02:53 PDT 2025
================
@@ -30,6 +30,16 @@ struct DemangledNameInfo {
/// \endcode
std::pair<size_t, size_t> BasenameRange;
+ /// A [start, end) pair for the function template arguments.
+ /// The basename is the name without scope qualifiers
+ /// and without template parameters. E.g.,
+ /// \code{.cpp}
+ /// void foo::bar<int>::someFunc<float>(int) const &&
+ /// ^ ^
+ /// start end
----------------
charles-zablit wrote:
In the CPlusPlusLanguage implementation, this is currently:
```cpp
return demangled_name.slice(info.BasenameRange.second,
info.ArgumentsRange.first);
```
My implementation in Swift is quite similar.
So in the example above, it should be `<float>`. I should move the end `^` to the right.
Are you saying that we should only return `float` instead and let the plugin decide how to format the brackets? i.e return `float` only and let the `.td` file decide if we should add the `<` and `>` ?
https://github.com/llvm/llvm-project/pull/150999
More information about the lldb-commits
mailing list