Everywhere: Fix typos - act III
Some checks are pending
CI / macOS, arm64, Sanitizer_CI, Clang (push) Waiting to run
CI / Linux, x86_64, Fuzzers_CI, Clang (push) Waiting to run
CI / Linux, x86_64, Sanitizer_CI, GNU (push) Waiting to run
CI / Linux, x86_64, Sanitizer_CI, Clang (push) Waiting to run
Package the js repl as a binary artifact / macOS, arm64 (push) Waiting to run
Package the js repl as a binary artifact / Linux, x86_64 (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Label PRs with merge conflicts / auto-labeler (push) Waiting to run
Push notes / build (push) Waiting to run

This commit is contained in:
Viktor Szépe 2025-04-09 17:02:30 +00:00 committed by Sam Atkins
commit 19f88f96dc
Notes: github-actions[bot] 2025-06-16 13:21:54 +00:00
12 changed files with 16 additions and 16 deletions

View file

@ -418,7 +418,7 @@ try_select_again:
if (error_or_marked_fd_count.value() != 0) { if (error_or_marked_fd_count.value() != 0) {
// Handle file system notifiers by making them normal events. // Handle file system notifiers by making them normal events.
for (size_t i = 1; i < thread_data.poll_fds.size(); ++i) { for (size_t i = 1; i < thread_data.poll_fds.size(); ++i) {
// FIXME: Make the check work under Android, pehaps use ALooper // FIXME: Make the check work under Android, perhaps use ALooper
#ifdef AK_OS_ANDROID #ifdef AK_OS_ANDROID
auto& notifier = *thread_data.notifier_by_index[i]; auto& notifier = *thread_data.notifier_by_index[i];
ThreadEventQueue::current().post_event(notifier, make<NotifierActivationEvent>(notifier.fd(), notifier.type())); ThreadEventQueue::current().post_event(notifier, make<NotifierActivationEvent>(notifier.fd(), notifier.type()));

View file

@ -99,7 +99,7 @@ int File::open_mode_to_options(OpenMode mode)
} }
// Some open modes, like `ReadWrite` imply the ability to create the file if it doesn't exist. // Some open modes, like `ReadWrite` imply the ability to create the file if it doesn't exist.
// Certain applications may not want this privledge, and for compability reasons, this is // Certain applications may not want this privilege, and for compatibility reasons, this is
// the easiest way to add this option. // the easiest way to add this option.
if (has_flag(mode, OpenMode::DontCreate)) if (has_flag(mode, OpenMode::DontCreate))
flags &= ~O_CREAT; flags &= ~O_CREAT;

View file

@ -487,7 +487,7 @@ private:
// - With a BigEndian stream and an EarlyChange of 1, this is used in the PDF format // - With a BigEndian stream and an EarlyChange of 1, this is used in the PDF format
// The fun begins when they decided to change from the former to the latter when moving // The fun begins when they decided to change from the former to the latter when moving
// from TIFF 5.0 to 6.0, and without including a way for files to be identified. // from TIFF 5.0 to 6.0, and without including a way for files to be identified.
// Fortunately, as the first byte of a LZW stream is a constant we can guess the endianess // Fortunately, as the first byte of a LZW stream is a constant we can guess the endianness
// and deduce the version from it. The first code is 0x100 (9-bits). // and deduce the version from it. The first code is 0x100 (9-bits).
if (encoded_bytes[0] == 0x00) if (encoded_bytes[0] == 0x00)
decoded_bytes = TRY(Compress::LzwDecompressor<LittleEndianInputBitStream>::decompress_all(encoded_bytes, 8, 0)); decoded_bytes = TRY(Compress::LzwDecompressor<LittleEndianInputBitStream>::decompress_all(encoded_bytes, 8, 0));

View file

@ -328,7 +328,7 @@ public:
} }
if (m_type == ScopeType::Function && m_bound_names.contains(identifier_group_name)) { if (m_type == ScopeType::Function && m_bound_names.contains(identifier_group_name)) {
// NOTE: Currently parser can't determine that named function expression assigment creates scope with binding for funciton name so function names are not considered as candidates to be optmized in global variables access // NOTE: Currently parser can't determine that named function expression assignment creates scope with binding for function name so function names are not considered as candidates to be optimized in global variables access
identifier_group.might_be_variable_in_lexical_scope_in_named_function_assignment = true; identifier_group.might_be_variable_in_lexical_scope_in_named_function_assignment = true;
} }

View file

@ -98,7 +98,7 @@ ThrowCompletionOr<Value> await(VM& vm, Value value)
promise->perform_then(on_fulfilled, on_rejected, {}); promise->perform_then(on_fulfilled, on_rejected, {});
// FIXME: Since we don't support context suspension, we attempt to "wait" for the promise to resolve // FIXME: Since we don't support context suspension, we attempt to "wait" for the promise to resolve
// by syncronously running all queued promise jobs. // by synchronously running all queued promise jobs.
if (auto* agent = vm.agent()) { if (auto* agent = vm.agent()) {
// Embedder case (i.e. LibWeb). Runs all promise jobs by performing a microtask checkpoint. // Embedder case (i.e. LibWeb). Runs all promise jobs by performing a microtask checkpoint.
agent->spin_event_loop_until(GC::create_function(vm.heap(), [success] { agent->spin_event_loop_until(GC::create_function(vm.heap(), [success] {

View file

@ -385,7 +385,7 @@ static i64 clip_double_to_sane_time(double value)
static constexpr auto min_double = static_cast<double>(NumericLimits<i64>::min()); static constexpr auto min_double = static_cast<double>(NumericLimits<i64>::min());
static constexpr auto max_double = static_cast<double>(NumericLimits<i64>::max()); static constexpr auto max_double = static_cast<double>(NumericLimits<i64>::max());
// The provided epoch millseconds value is potentially out of range for AK::Duration and subsequently // The provided epoch milliseconds value is potentially out of range for AK::Duration and subsequently
// get_time_zone_offset(). We can safely assume that the TZDB has no useful information that far // get_time_zone_offset(). We can safely assume that the TZDB has no useful information that far
// into the past and future anyway, so clamp it to the i64 range. // into the past and future anyway, so clamp it to the i64 range.
if (value < min_double) if (value < min_double)

View file

@ -35,7 +35,7 @@ String const& SourceCode::code() const
void SourceCode::fill_position_cache() const void SourceCode::fill_position_cache() const
{ {
constexpr size_t predicted_mimimum_cached_positions = 8; constexpr size_t predicted_minimum_cached_positions = 8;
constexpr size_t minimum_distance_between_cached_positions = 32; constexpr size_t minimum_distance_between_cached_positions = 32;
constexpr size_t maximum_distance_between_cached_positions = 8192; constexpr size_t maximum_distance_between_cached_positions = 8192;
@ -46,7 +46,7 @@ void SourceCode::fill_position_cache() const
size_t line = 1; size_t line = 1;
size_t column = 1; size_t column = 1;
size_t offset_of_last_starting_point = 0; size_t offset_of_last_starting_point = 0;
m_cached_positions.ensure_capacity(predicted_mimimum_cached_positions + m_code.bytes().size() / maximum_distance_between_cached_positions); m_cached_positions.ensure_capacity(predicted_minimum_cached_positions + m_code.bytes().size() / maximum_distance_between_cached_positions);
m_cached_positions.append({ .line = 1, .column = 1, .offset = 0 }); m_cached_positions.append({ .line = 1, .column = 1, .offset = 0 });
Utf8View const view(m_code); Utf8View const view(m_code);

View file

@ -71,9 +71,9 @@ describe("correct behaviour", () => {
}); });
test("gets undefined in completed state", () => { test("gets undefined in completed state", () => {
const ninethRunResult = runGenerator("bad8", false); const ninthRunResult = runGenerator("bad8", false);
expect(ninethRunResult.value).toBeUndefined(); expect(ninthRunResult.value).toBeUndefined();
expect(ninethRunResult.done).toBeTrue(); expect(ninthRunResult.done).toBeTrue();
}); });
async function* implicitReturnFunction() { async function* implicitReturnFunction() {

View file

@ -168,7 +168,7 @@ describe("behavior with exceptions", () => {
expect(inCatch).toBeTrue(); expect(inCatch).toBeTrue();
}); });
test.xfail("normal error and multiple disposing erorrs give chaining suppressed errors", () => { test.xfail("normal error and multiple disposing errors give chaining suppressed errors", () => {
let inCatch = false; let inCatch = false;
try { try {
using a = { [Symbol.dispose]() { using a = { [Symbol.dispose]() {
@ -345,7 +345,7 @@ describe("using is still a valid variable name", () => {
}); });
}); });
describe("syntax errors / werid artifacts which remain valid", () => { describe("syntax errors / weird artifacts which remain valid", () => {
test("no patterns in using", () => { test("no patterns in using", () => {
expect("using {a} = {}").not.toEval(); expect("using {a} = {}").not.toEval();
expect("using a, {a} = {}").not.toEval(); expect("using a, {a} = {}").not.toEval();

View file

@ -242,7 +242,7 @@ DecoderErrorOr<NonnullOwnPtr<VideoFrame>> FFmpegVideoDecoder::get_decoded_frame(
case AVERROR(EINVAL): case AVERROR(EINVAL):
return DecoderError::with_description(DecoderErrorCategory::Invalid, "FFmpeg codec has not been opened"sv); return DecoderError::with_description(DecoderErrorCategory::Invalid, "FFmpeg codec has not been opened"sv);
default: default:
return DecoderError::format(DecoderErrorCategory::Unknown, "FFmpeg codec encountered an unexpected error retreiving frames with code {:x}", result); return DecoderError::format(DecoderErrorCategory::Unknown, "FFmpeg codec encountered an unexpected error retrieving frames with code {:x}", result);
} }
} }

View file

@ -847,7 +847,7 @@ private:
} }
// ICU 72 introduced the use of NBSP to separate time fields and day periods. All major browsers have found that // ICU 72 introduced the use of NBSP to separate time fields and day periods. All major browsers have found that
// this significantly breaks web compatibilty, and they all replace these spaces with normal ASCII spaces. See: // this significantly breaks web compatibility, and they all replace these spaces with normal ASCII spaces. See:
// //
// https://bugzilla.mozilla.org/show_bug.cgi?id=1806042 // https://bugzilla.mozilla.org/show_bug.cgi?id=1806042
// https://bugs.webkit.org/show_bug.cgi?id=252147 // https://bugs.webkit.org/show_bug.cgi?id=252147

View file

@ -1149,7 +1149,7 @@ ParseResult<CodeSection::Code> CodeSection::Code::parse(Stream& stream)
ScopeLogger<WASM_BINPARSER_DEBUG> logger("Code"sv); ScopeLogger<WASM_BINPARSER_DEBUG> logger("Code"sv);
auto size = TRY_READ(stream, LEB128<u32>, ParseError::InvalidSize); auto size = TRY_READ(stream, LEB128<u32>, ParseError::InvalidSize);
// Emprically, if there are `size` bytes to be read, then there's around // Empirically, if there are `size` bytes to be read, then there's around
// `size / 2` instructions, so we pass that as our size hint. // `size / 2` instructions, so we pass that as our size hint.
auto func = TRY(Func::parse(stream, size / 2)); auto func = TRY(Func::parse(stream, size / 2));