[Lldb-commits] [PATCH] D39844: CompilerType: Add ability to retrieve an integral template argument

Zachary Turner via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Nov 9 10:24:43 PST 2017


zturner added inline comments.


================
Comment at: unittests/Symbol/TestClangASTContext.cpp:418-419
 
-    arg = m_ast->GetTemplateArgument(t.GetOpaqueQualType(), 1, kind);
-    EXPECT_EQ(kind, eTemplateArgumentKindIntegral);
-    EXPECT_EQ(arg, int_type);
+    EXPECT_EQ(m_ast->GetTemplateArgumentKind(t.GetOpaqueQualType(), 1),
+              eTemplateArgumentKindIntegral);
+    auto p = m_ast->GetIntegralTemplateArgument(t.GetOpaqueQualType(), 1);
----------------
What about booleans, functions, pointers, references, parameter packs, and everything else?  Even if you want to limit the scope of your change to exclude parameter packs, I think we should handle the other stuff.  If it already works, can you add some tests for those cases?


https://reviews.llvm.org/D39844





More information about the lldb-commits mailing list