mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-29 16:21:29 +00:00
IDLGenerators: Don't duplicate include statements for each import
Previously, all `#import` statements generated two identical includes in the generated C++ source code.
This commit is contained in:
parent
fcf1a2a287
commit
3eb07a9b8b
Notes:
sideshowbarker
2024-07-17 07:09:53 +09:00
Author: https://github.com/tcl3 Commit: https://github.com/SerenityOS/serenity/commit/3eb07a9b8b Pull-request: https://github.com/SerenityOS/serenity/pull/24088
|
@ -3762,9 +3762,6 @@ void generate_namespace_implementation(IDL::Interface const& interface, StringBu
|
|||
|
||||
)~~~");
|
||||
|
||||
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"~~~(
|
||||
|
@ -4028,9 +4025,6 @@ void generate_constructor_implementation(IDL::Interface const& interface, String
|
|||
}
|
||||
}
|
||||
|
||||
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"~~~(
|
||||
|
@ -4301,9 +4295,6 @@ void generate_prototype_implementation(IDL::Interface const& interface, StringBu
|
|||
)~~~");
|
||||
}
|
||||
|
||||
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"~~~(
|
||||
|
@ -4594,9 +4585,6 @@ void generate_global_mixin_implementation(IDL::Interface const& interface, Strin
|
|||
|
||||
)~~~");
|
||||
|
||||
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"~~~(
|
||||
|
|
Loading…
Reference in a new issue