mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:57:44 +00:00
Everywhere: Stop using NonnullOwnPtrVector
Same as NonnullRefPtrVector: weird semantics, questionable benefits.
This commit is contained in:
parent
689ca370d4
commit
359d6e7b0b
111 changed files with 517 additions and 503 deletions
|
@ -359,7 +359,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
}
|
||||
|
||||
// First, resolve the linked modules
|
||||
NonnullOwnPtrVector<Wasm::ModuleInstance> linked_instances;
|
||||
Vector<NonnullOwnPtr<Wasm::ModuleInstance>> linked_instances;
|
||||
Vector<Wasm::Module> linked_modules;
|
||||
for (auto& name : modules_to_link_in) {
|
||||
auto parse_result = parse(name);
|
||||
|
@ -370,7 +370,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
linked_modules.append(parse_result.release_value());
|
||||
Wasm::Linker linker { linked_modules.last() };
|
||||
for (auto& instance : linked_instances)
|
||||
linker.link(instance);
|
||||
linker.link(*instance);
|
||||
auto link_result = linker.finish();
|
||||
if (link_result.is_error()) {
|
||||
warnln("Linking imported module '{}' failed", name);
|
||||
|
@ -387,7 +387,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
|
||||
Wasm::Linker linker { parse_result.value() };
|
||||
for (auto& instance : linked_instances)
|
||||
linker.link(instance);
|
||||
linker.link(*instance);
|
||||
|
||||
if (export_all_imports) {
|
||||
HashMap<Wasm::Linker::Name, Wasm::ExternValue> exports;
|
||||
|
|
|
@ -112,7 +112,7 @@ static void dump(XML::Node const& node)
|
|||
color(ColorRole::Reset);
|
||||
|
||||
for (auto& node : element.children)
|
||||
dump(node);
|
||||
dump(*node);
|
||||
|
||||
color(ColorRole::Tag);
|
||||
out("</{}>", element.name);
|
||||
|
@ -391,12 +391,12 @@ static void do_run_tests(XML::Document& document)
|
|||
Queue<XML::Node*> suites;
|
||||
auto dump_cases = [&](auto& root) {
|
||||
for (auto& node : root.children) {
|
||||
auto element = node.content.template get_pointer<XML::Node::Element>();
|
||||
auto element = node->content.template get_pointer<XML::Node::Element>();
|
||||
if (!element)
|
||||
continue;
|
||||
if (element->name != "TESTCASES" && element->name != "TEST")
|
||||
continue;
|
||||
suites.enqueue(&node);
|
||||
suites.enqueue(node);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue