mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-22 12:35:14 +00:00
LibWeb: Include relevant headers in IDL constructor implementations
Similarly to implementations of prototype methods, the implementations of constructors sometimes require generated types.
This commit is contained in:
parent
a7f2d46b49
commit
b172b56757
Notes:
sideshowbarker
2024-07-17 16:20:16 +09:00
Author: https://github.com/IdanHo Commit: https://github.com/SerenityOS/serenity/commit/b172b56757 Pull-request: https://github.com/SerenityOS/serenity/pull/13424 Reviewed-by: https://github.com/alimpfard ✅
1 changed files with 8 additions and 0 deletions
|
@ -2657,6 +2657,14 @@ void generate_constructor_implementation(IDL::Interface const& interface)
|
|||
# include <LibWeb/URL/@name@.h>
|
||||
#endif
|
||||
|
||||
)~~~");
|
||||
|
||||
for (auto& path : interface.required_imported_paths)
|
||||
generate_include_for(generator, path);
|
||||
|
||||
emit_includes_for_all_imports(interface, generator, interface.pair_iterator_types.has_value());
|
||||
|
||||
generator.append(R"~~~(
|
||||
// FIXME: This is a total hack until we can figure out the namespace for a given type somehow.
|
||||
using namespace Web::CSS;
|
||||
using namespace Web::DOM;
|
||||
|
|
Loading…
Add table
Reference in a new issue