summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Userland/Libraries/LibCpp/AST.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Userland/Libraries/LibCpp/AST.cpp b/Userland/Libraries/LibCpp/AST.cpp
index 8fb5cc52cd..344858d7e0 100644
--- a/Userland/Libraries/LibCpp/AST.cpp
+++ b/Userland/Libraries/LibCpp/AST.cpp
@@ -61,6 +61,10 @@ NonnullRefPtrVector<Declaration> FunctionDeclaration::declarations() const
for (auto& arg : m_parameters) {
declarations.append(arg);
}
+
+ if (m_definition)
+ declarations.append(m_definition->declarations());
+
return declarations;
}