mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-07 01:56:38 +00:00
LibCpp: Consider declarations inside a function's body
... in FunctionDeclaration::declarations()
This commit is contained in:
parent
ab79599a5e
commit
b5da0b71e5
Notes:
sideshowbarker
2024-07-18 17:02:44 +09:00
Author: https://github.com/itamar8910
Commit: b5da0b71e5
Pull-request: https://github.com/SerenityOS/serenity/pull/7605
Reviewed-by: https://github.com/awesomekling
1 changed files with 4 additions and 0 deletions
|
@ -61,6 +61,10 @@ NonnullRefPtrVector<Declaration> FunctionDeclaration::declarations() const
|
||||||
for (auto& arg : m_parameters) {
|
for (auto& arg : m_parameters) {
|
||||||
declarations.append(arg);
|
declarations.append(arg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (m_definition)
|
||||||
|
declarations.append(m_definition->declarations());
|
||||||
|
|
||||||
return declarations;
|
return declarations;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue