[Lldb-commits] [PATCH] D39844: CompilerType: Add ability to retrieve an integral template argument
Pavel Labath via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Thu Nov 9 07:24:14 PST 2017
labath added inline comments.
================
Comment at: source/API/SBType.cpp:422
+ CompilerType template_arg_type =
+ m_opaque_sp->GetCompilerType(false).GetTypeTemplateArgument(idx);
+ if (template_arg_type.IsValid())
----------------
I should point out that this changes the behaviour of `SBType::GetTemplateArgumentType` slightly.
Previously, for an integral template argument (e.g. `foo<47>`), it returned the *type* of the integer argument (i.e. `int`), where as now it will return nothing.
I think this is the behavior that makes most sense for the underlying API, but if you're worried about compatibility, I can add a special case here (I am not worried as I don't think there is anything reasonable the user could have done with the returned value anyway).
https://reviews.llvm.org/D39844
More information about the lldb-commits
mailing list