1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 23:07:35 +00:00

Everywhere: Run clang-format

This commit is contained in:
Idan Horowitz 2022-04-01 20:58:27 +03:00 committed by Linus Groh
parent 0376c127f6
commit 086969277e
1665 changed files with 8479 additions and 8479 deletions

View file

@ -84,8 +84,7 @@ Result Configuration::execute(Interpreter& interpreter)
void Configuration::dump_stack()
{
auto print_value = []<typename... Ts>(CheckedFormatString<Ts...> format, Ts... vs)
{
auto print_value = []<typename... Ts>(CheckedFormatString<Ts...> format, Ts... vs) {
DuplexMemoryStream memory_stream;
Printer { memory_stream }.print(vs...);
ByteBuffer buffer = memory_stream.copy_into_contiguous_buffer();

View file

@ -2155,7 +2155,7 @@ VALIDATE_INSTRUCTION(call_indirect)
return {};
}
ErrorOr<void, ValidationError> Validator::validate(const Instruction& instruction, Stack& stack, bool& is_constant)
ErrorOr<void, ValidationError> Validator::validate(Instruction const& instruction, Stack& stack, bool& is_constant)
{
switch (instruction.opcode().value()) {
#define M(name, integer_value) \
@ -2194,7 +2194,7 @@ ErrorOr<Validator::ExpressionTypeResult, ValidationError> Validator::validate(Ex
return ExpressionTypeResult { stack.release_vector(), is_constant_expression };
}
bool Validator::Stack::operator==(const Stack& other) const
bool Validator::Stack::operator==(Stack const& other) const
{
if (!m_did_insert_unknown_entry && !other.m_did_insert_unknown_entry)
return static_cast<Vector<StackEntry> const&>(*this) == static_cast<Vector<StackEntry> const&>(other);

View file

@ -416,14 +416,15 @@ void Printer::print(Wasm::ImportSection::Import const& import)
{
TemporaryChange change { m_indent, m_indent + 1 };
import.description().visit(
[this](auto const& type) { print(type); },
[this](auto const& type) { print(type);
},
[this](TypeIndex const& index) {
print_indent();
print("(type index {})\n", index.value());
print_indent();
print("(type index {})\n", index.value());
});
}
print_indent();
print(")\n");
}
print_indent();
print(")\n");
}
void Printer::print(Wasm::Instruction const& instruction)
@ -671,7 +672,6 @@ void Printer::print(Wasm::Reference const& value)
[](Wasm::Reference::Null const&) { return String("null"); },
[](auto const& ref) { return String::number(ref.address.value()); }));
}
}
HashMap<Wasm::OpCode, String> Wasm::Names::instruction_names {