diff --git a/src/TaskCompareParamLists.cpp b/src/TaskCompareParamLists.cpp index 722871e..d91850a 100644 --- a/src/TaskCompareParamLists.cpp +++ b/src/TaskCompareParamLists.cpp @@ -72,10 +72,11 @@ bool TaskCompareParamLists::equal( // How do we compare? if (type_value[0]) { - ret = !m_tref_comp.equal( + ret &= m_tref_comp.equal( type_value[0]->getDflt(), type_value[1]->getDflt()); } else if (expr_value[0] && expr_value[0]->getDflt()) { + DEBUG("TODO: Compare value-type parameters"); expr_value[0]->getDflt()->accept(m_this); } else { DEBUG("FATAL: didn't hit anything"); diff --git a/src/TaskGetSpecializedTemplateType.cpp b/src/TaskGetSpecializedTemplateType.cpp index 62deb71..0dd4793 100644 --- a/src/TaskGetSpecializedTemplateType.cpp +++ b/src/TaskGetSpecializedTemplateType.cpp @@ -58,6 +58,7 @@ ast::ISymbolRefPath *TaskGetSpecializedTemplateType::find( // Search through the list of available specializations for // a matching one TaskCompareParamLists p_comp(m_factory); + DEBUG("There are %d existing specializations", type_up->getSpec_types().size()); for (int32_t i=0; igetSpec_types().size(); i++) { ast::ISymbolTypeScope *sym_type_s_t = type_up->getSpec_types().at(i).get(); ast::ITypeScope *type_s_t = dynamic_cast(sym_type_s_t->getTarget()); diff --git a/tests/src/TestBase.cpp b/tests/src/TestBase.cpp index 6e44fd7..4e3e33a 100644 --- a/tests/src/TestBase.cpp +++ b/tests/src/TestBase.cpp @@ -156,8 +156,10 @@ void TestBase::parseLink( const std::string &name, ast::IGlobalScopeUP &global, ast::ISymbolScopeUP &root) { + std::vector files; global = ast::IGlobalScopeUP(parse(marker_l, content, name)); - root = ast::ISymbolScopeUP(link(marker_l, {global.get()})); + files.push_back(global.get()); + root = ast::ISymbolScopeUP(link(marker_l, files)); } std::pair TestBase::parseLink( @@ -168,7 +170,9 @@ std::pair TestBase::parseLink( ast::IGlobalScope *global = parse(marker_l, content, name, process_doc_comments); ast::ISymbolScope *root = 0; if (!marker_l->hasSeverity(MarkerSeverityE::Error)) { - root = link(marker_l, {global}); + std::vector files; + files.push_back(global); + root = link(marker_l, files); } return {global, root}; diff --git a/tests/src/TestBase.h b/tests/src/TestBase.h index aac51ad..31a016a 100644 --- a/tests/src/TestBase.h +++ b/tests/src/TestBase.h @@ -53,7 +53,7 @@ class TestBase : public ::testing::Test { bool process_doc_comments=false); ast::ISymbolScope *link( - parser::IMarkerListener *marker_l, + parser::IMarkerListener *marker_l, const std::vector &files );