summaryrefslogtreecommitdiff
path: root/lldb/test/API/lang/cpp/template-arguments/main.cpp
AgeCommit message (Collapse)Author
2025-02-17[lldb][TypeSystemClang] Add support for floating point template argument ↵Michael Buch
constants (#127206) This patch adds support for template arguments of `clang::TemplateArgument::ArgKind::StructuralValue` kind (added in https://github.com/llvm/llvm-project/pull/78041). These are used for non-type template parameters such as floating point constants. When LLDB created `clang::NonTypeTemplateParmDecl`s, it previously assumed integral values, this patch accounts for structural values too. Anywhere LLDB assumed a `DW_TAG_template_value_parameter` was `Integral`, it will now also check for `StructuralValue`, and will unpack the `TemplateArgument` value and type accordingly. We can rely on the fact that any `TemplateArgument` of `StructuralValue` kind that the `DWARFASTParserClang` creates will have a valid value, because it gets those from `DW_AT_const_value`.
2025-02-13[lldb][SBAPI] Add new SBType::GetTemplateParameterValue API (#126901)Michael Buch
This patch adds a new API to `SBType` to retrieve the value of a template parameter given an index. We re-use the `TypeSystemClang::GetIntegralTemplateArgument` for this and thus currently only supports integral non-type template parameters. Types like float/double are not supported yet. rdar://144395216
2020-10-15[lldb] Explicitly test the template argument SB APIRaphael Isemann