mirror of https://github.com/boa-dev/boa.git
Tree:
43354a333c
add-vhs-ci
benchmarks
control-flow-graph
expect-lints
feature/node_span
feature/snapshot
features
gh-readonly-queue/main/pr-2877-b0ddf5eed00a53281d67fc7d846233fc0d99ce9c
gh-readonly-queue/main/pr-3144-8e48cec73fae708420b9af88813d4870243c491a
main
nan-boxing
optimization/static-shapes
real_conformance
reduce-environment-allocations
refactor/interner
refactor/register-vm
releases/0.17
releases/0.19
semver_checks
tco
utility-crate
wasm-debugger
nightly
v0.10
v0.11
v0.12
v0.13
v0.14
v0.15
v0.16
v0.17
v0.17.1
v0.17.2
v0.17.3
v0.18
v0.19
v0.19.1
v0.2.0
v0.2.1
v0.3.0
v0.4.0
v0.5.0
v0.5.1
v0.6.0
v0.7.0
v0.8.0
v0.9.0
${ noResults }
2062 Commits (43354a333c0242d623f2d51f1eaf86832b038dda)
Author | SHA1 | Message | Date |
---|---|---|---|
José Julián Espina | 5a201daa98 |
Rename `check_parser` and `Identifier` (#2576)
Extracted from #2411 to reduce its size a bit. This PR: - Renames `Identifier` to `IdentifierName`, which is the name stated in the spec. - Renames the utility function `check_parser` to `check_script_parser` to prepare for modules. - Adds some missing `#[inline]` and rewrites some patterns. |
2 years ago |
José Julián Espina | b7782ab2c7 |
Fix failing collator tests (#2575)
This Pull Request fixes the regressed tests caused by the ICU4X version bump. |
2 years ago |
raskad | bd0652fe28 |
Add early errors for escaped identifiers (#2546)
This Pull Request changes the following: - Add early errors for escaped characters in object and class setters and getters. - Add early errors for escaped characters in class `static`. - Add early errors for escaped characters in `new.target`. - Add early errors for legacy octal/decial escapes that are used in string literals before a `"use strict"` directive. |
2 years ago |
raskad | aa8e0c55dd |
Update icu dependencies (#2574)
This Pull Request changes the following: - Update icu dependencies - Regenerate icu data |
2 years ago |
raskad | e6a1c3789d |
Fix rust 1.67 lints (#2567)
This Pull Request changes the following: - Fix rust 1.67 lints |
2 years ago |
dependabot[bot] | 753cab6a3b |
Bump num_enum from 0.5.7 to 0.5.9 (#2564)
Bumps [num_enum](https://github.com/illicitonion/num_enum) from 0.5.7 to 0.5.9. <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/illicitonion/num_enum/commits/0.5.9">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=num_enum&package-manager=cargo&previous-version=0.5.7&new-version=0.5.9)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> |
2 years ago |
dependabot[bot] | 5f6ec59ec1 |
Bump clap from 4.1.1 to 4.1.4 (#2563)
Bumps [clap](https://github.com/clap-rs/clap) from 4.1.1 to 4.1.4. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/releases">clap's releases</a>.</em></p> <blockquote> <h2>v4.1.4</h2> <h2>[4.1.4] - 2023-01-24</h2> <h3>Fixes</h3> <ul> <li><em>(help)</em> Respect <code>disable_colored_help</code> when using <code>arg_required_else_help</code></li> </ul> <h3>Performance</h3> <ul> <li>Speed up compiling <code>arg!</code> macro</li> </ul> <h2>v4.1.3</h2> <h2>[4.1.3] - 2023-01-23</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> Improve suggested flag/value/subcommand when two share a long preifx</li> <li><em>(error)</em> When suggesting one of several subcommands, use the plural <code>subcommands</code>, rather than <code>subcommand</code></li> </ul> <h2>v4.1.2</h2> <h2>[4.1.2] - 2023-01-23</h2> <h3>Fixes</h3> <ul> <li>In documentation, refer to <code>get_flag</code>, rather than <code>get_one::<bool></code></li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap's changelog</a>.</em></p> <blockquote> <h2>[4.1.4] - 2023-01-24</h2> <h3>Fixes</h3> <ul> <li><em>(help)</em> Respect <code>disable_colored_help</code> when using <code>arg_required_else_help</code></li> </ul> <h3>Performance</h3> <ul> <li>Speed up compiling <code>arg!</code> macro</li> </ul> <h2>[4.1.3] - 2023-01-23</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> Improve suggested flag/value/subcommand when two share a long preifx</li> <li><em>(error)</em> When suggesting one of several subcommands, use the plural <code>subcommands</code>, rather than <code>subcommand</code></li> </ul> <h2>[4.1.2] - 2023-01-23</h2> <h3>Fixes</h3> <ul> <li>In documentation, refer to <code>get_flag</code>, rather than <code>get_one::<bool></code></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
José Julián Espina | 097f85e409 |
First batch of `no_std` support for some sub-crates (#2544)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> This Pull Request enables support for `no_std` targets on some of our sub-crates. I intentionally left out `boa_ast` and `boa_cli` because they're the largest crates we have after `boa_engine`. `boa_gc` is a monster on its own, because we'll need to design a `no_std` multithreaded GC. Anyways, this changes the following: - Adds support for `no_std` on `boa_unicode`. - Adds support for `no_std` on `boa_profiler`. - Adds support for `no_std` on `boa_interner`. - Adds support for `no_std` on `boa_icu_provider`. |
2 years ago |
raskad | 787d4a8bc5 |
Fix double property access on assignment ops (#2551)
Currently the compilation of assignment operators leads to a double object property access, both on the get and set access. While this refactor adds special access handling instead of using the existing `access_set` and `access_get` functions, it fixes the double access and should also make the resulting code more efficient. |
2 years ago |
dependabot[bot] | 98a4ee7b8b |
Bump toml from 0.5.11 to 0.6.0 (#2560)
Bumps [toml](https://github.com/toml-rs/toml) from 0.5.11 to 0.6.0. <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 878bd9d4cf |
Bump test262 from `2ac0d3c` to `ac1c354` (#2557)
Bumps [test262](https://github.com/tc39/test262) from `2ac0d3c` to `ac1c354`. <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 64293d5c29 |
Bump arbitrary from 1.2.2 to 1.2.3 (#2558)
Bumps [arbitrary](https://github.com/rust-fuzz/arbitrary) from 1.2.2 to 1.2.3. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/rust-fuzz/arbitrary/blob/main/CHANGELOG.md">arbitrary's changelog</a>.</em></p> <blockquote> <h2>1.2.3</h2> <p>Released 2023-01-20.</p> <h3>Fixed</h3> <ul> <li>The <code>derive(Arbitrary)</code> will now annotate the generated <code>impl</code>s with a <code>#[automatically_derived]</code> attribute to indicate to e.g. clippy that lints should not fire for the code within the derived implementation.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/rust-fuzz/arbitrary/commits/v1.2.3">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=arbitrary&package-manager=cargo&previous-version=1.2.2&new-version=1.2.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> |
2 years ago |
José Julián Espina | 408809dda4 |
Pin tarpaulin version to 0.22 (#2562)
Our CI broke because the new version of `tarpaulin` released more assets than the default 'travis.tar.gz'. We'll have to pin our version of `tarpaulin` until the issue gets fixed. Co-authored-by: raskad <32105367+raskad@users.noreply.github.com> |
2 years ago |
raskad | 6c8e9c7070 |
Avoid creating `prototype` property on methods (#2553)
This Pull Request changes the following: - Stop creating a `prototype` property on class methods by passing a flag to the relevant opcodes. |
2 years ago |
raskad | 9355c77e0b |
Fix error for static class methods named `prototype` (#2552)
This Pull Request changes the following: - Remove wrong early errors for static class methods with the computed property name `prototype`. - Switch static class method definition opcodes from `__define_own_property__` to `define_property_or_throw` to correctly throw runtime errors on property redefinitions. |
2 years ago |
raskad | 96a6e0a346 |
Return the correct value from a statement list (#2554)
When compiling a statement list we need to make sure that the last expression that returns a value is compiled with the `use_expr` flag. Currently we set `use_expr` on the last statement of the statement list. This leads to incorrect returns when the last statement does not return a value. This PR fixes this by looking up the last value returning expression in a statement list and setting the `use_expr` appropriately. |
2 years ago |
José Julián Espina | 7c9eef8edc |
Improve the design of ephemerons in our GC (#2530)
This PR changes the following: - Modifies `EphemeronBox` to be more akin to `GcBox`, with its own header, roots and markers. This also makes it more similar to [Racket's](https://docs.racket-lang.org/reference/ephemerons.html) implementation. - Removes `EPHEMERON_QUEUE`. - Ephemerons are now tracked on a special `weak_start` linked list, instead of `strong_start` which is where all other GC boxes live. - Documents all unsafe blocks. - Documents our current garbage collection algorithm. I hope this'll clarify a bit what exactly are we doing on every garbage collection. - Renames/removes some functions. |
2 years ago |
raskad | f19467ab1d |
Fix some HoistableDeclaration parsing errors (#2532)
This Pull Request hanges the following: - Add early errors for invalid `yield` and `await` usage in function parameters. - Add missing function types to hoistable ordering. - Do not attempt to parse `async` with a following line terminator as an async function. |
2 years ago |
dependabot[bot] | 0d599293fd |
Bump rustyline from 10.1.0 to 10.1.1 (#2549)
Bumps [rustyline](https://github.com/kkawakam/rustyline) from 10.1.0 to 10.1.1. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/kkawakam/rustyline/releases">rustyline's releases</a>.</em></p> <blockquote> <h2>10.1.1</h2> <p>Rollbacks incompatible changes relative to edition 2018 (<a href="https://github-redirect.dependabot.com/kkawakam/rustyline/issues/671">#671</a>) <strong>Full Changelog</strong>: <a href="https://github.com/kkawakam/rustyline/compare/v10.1.0...v10.1.1">https://github.com/kkawakam/rustyline/compare/v10.1.0...v10.1.1</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 2d8c6102ad |
Bump toml from 0.5.10 to 0.5.11 (#2548)
Bumps [toml](https://github.com/toml-rs/toml) from 0.5.10 to 0.5.11. <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | eed1134dc0 |
Bump serde_yaml from 0.9.16 to 0.9.17 (#2550)
Bumps [serde_yaml](https://github.com/dtolnay/serde-yaml) from 0.9.16 to 0.9.17. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/dtolnay/serde-yaml/releases">serde_yaml's releases</a>.</em></p> <blockquote> <h2>0.9.17</h2> <ul> <li>Improve Debug representation of some error messages</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
Kevin | 90d310b184 |
Labelled ByteCompiler Fix (#2534)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> This Pull Request addresses #2295, and another case that I came across when I was adding `Break` to the `ByteCompiler` I did have a question that came up during this regarding the spec. We currently don't implement the [BreakableStatement](https://tc39.es/ecma262/#prod-BreakableStatement). Any thoughts on whether we should be? Especially since `BreakableStatement` seems to be a bit of a inaccurate since `LabelledStatement` is breakable too. It changes the following: - Moves handling of label jump out of `compile_block` and into `compile_labelled`. - Adds a couple more tests to keep track of `LabelledStatement` breaks. Co-authored-by: Ness <Kevin.Ness@Staples.com> |
2 years ago |
José Julián Espina | 5ab0aa21cc |
Implement host hooks and job queues APIs (#2529)
Follows from #2528, and should complement #2411 to implement the module import hooks. ~~Similarly to the Intl/ICU4X PR (#2478), this has a lot of trivial changes caused by the new lifetimes. I thought about passing the queue and the hooks by value, but it was very painful having to wrap everything with `Rc` in order to be accessible by the host. In contrast, `&dyn` can be easily provided by the host and has the advantage of not requiring additional allocations, with the downside of adding two more lifetimes to our `Context`, but I think it's worth.~~ I was able to unify all lifetimes into the shortest one of the three, making our API just like before! Changes: - Added a new `HostHooks` trait and a `&dyn HostHooks` field to `Context`. This allows hosts to implement the trait for their custom type, then pass it to the context. - Added a new `JobQueue` trait and a `&dyn JobQueue` field to our `Context`, allowing custom event loops and other fun things. - Added two simple implementations of `JobQueue`: `IdleJobQueue` which does nothing and `SimpleJobQueue` which runs all jobs until all successfully complete or until any of them throws an error. - Modified `boa_cli` to run all jobs until the queue is empty, even if a job returns `Err`. This also prints all errors to the user. |
2 years ago |
José Julián Espina | 08e5e46117 |
Make `JsSymbol` thread-safe (#2539)
The section about `Symbol` on the [specification](https://tc39.es/ecma262/#sec-ecmascript-language-types-symbol-type) says: > The Symbol type is the set of all non-String values that may be used as the key of an Object property ([6.1.7](https://tc39.es/ecma262/#sec-object-type)). Each possible Symbol value is unique and immutable. Our previous implementation of `JsSymbol` used `Rc` and a thread local `Cell<usize>`. However, this meant that two different symbols in two different threads could share the same hash, making symbols not unique. Also, the [GlobalSymbolRegistry](https://tc39.es/ecma262/#table-globalsymbolregistry-record-fields) is meant to be shared by all realms, including realms that are not in the same thread as the main one; this forces us to replace our current thread local global symbol registry with a thread-safe one that uses `DashMap` for concurrent access. However, the global symbol registry uses `JsString`s as keys and values, which forces us to either use `Vec<u16>` instead (wasteful and needs to allocate to convert to `JsString` on each access) or make `JsString` thread-safe with an atomic counter. For this reason, I implemented the second option. This PR changes the following: - Makes `JsSymbol` thread-safe by using Arc instead of Rc, and making `SYMBOL_HASH_COUNT` an `AtomicU64`. - ~~Makes `JsString` thread-safe by using `AtomicUsize` instead of `Cell<usize>` for its ref count.~~ EDIT: Talked with @jasonwilliams and we decided to use `Box<[u16]>` for the global registry instead, because this won't penalize common usage of `JsString`, which is used a LOT more than `JsSymbol`. - Makes the `GLOBAL_SYMBOL_REGISTRY` truly global, using `DashMap` as our global map that is shared by all threads. - Replaces some thread locals with thread-safe alternatives, such as static arrays and static indices. - Various improvements to all related code for this. |
2 years ago |
dependabot[bot] | 20af6a7f17 |
Bump proc-macro2 from 1.0.49 to 1.0.50 (#2541)
Bumps [proc-macro2](https://github.com/dtolnay/proc-macro2) from 1.0.49 to 1.0.50. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/dtolnay/proc-macro2/releases">proc-macro2's releases</a>.</em></p> <blockquote> <h2>1.0.50</h2> <ul> <li>Implement Hash for proc_macro2::LineColumn (<a href="https://github-redirect.dependabot.com/dtolnay/proc-macro2/issues/362">#362</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
raskad | 1269381ac8 |
Correctly parse consecutive semicolons (#2533)
This Pull Request changes the following: - Do not skip consecutive semicolons while parsing a `StatementList`. - Expect semicolon in `LexicalDeclaration` and add an special case for `for` loop parsing. - Adjust `StatementList` compilation to skip empty statements. - Adjust/add tests to make sure consecutive semicolons are correctly parsed. |
2 years ago |
dependabot[bot] | b937a60602 |
Bump test262 from `e1048d0` to `2ac0d3c` (#2538)
Bumps [test262](https://github.com/tc39/test262) from `e1048d0` to `2ac0d3c`. <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | cd85040544 |
Bump clap from 4.0.32 to 4.1.1 (#2537)
Bumps [clap](https://github.com/clap-rs/clap) from 4.0.32 to 4.1.1. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/releases">clap's releases</a>.</em></p> <blockquote> <h2>v4.1.1</h2> <h2>[4.1.1] - 2023-01-14</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> Small softening attempt for "unexpected argument" error</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap's changelog</a>.</em></p> <blockquote> <h2>[4.1.1] - 2023-01-14</h2> <h3>Fixes</h3> <ul> <li><em>(error)</em> Small softening attempt for "unexpected argument" error</li> </ul> <h2>[4.1.0] - 2023-01-13</h2> <h3>Compatibility</h3> <p>MSRV changed to 1.64.0</p> <p>For apps with custom <code>--help</code> and <code>--version</code> flags:</p> <ul> <li>Descriptions for <code>--help</code> and <code>--version</code> changed</li> </ul> <p>When apps have errors imitating clap's error style:</p> <ul> <li>Error message style was changed, including <ul> <li>Moving away from "did you mean" to tips</li> <li>Leading letter is lower case</li> <li>"For more" added some punctuation</li> </ul> </li> </ul> <h3>Features</h3> <ul> <li><code>ArgMatches::get_occurrences</code> support for argument values to be grouped by their occurrence</li> </ul> <h3>Fixes</h3> <ul> <li><em>(derive)</em> Allow <code>upgrade_from</code> when arguments / subcommands are explicitly marked as required</li> <li><em>(help)</em> Try be more clearer and succinct with <code>--help</code> and <code>--version</code> (also helps with overflow)</li> <li><em>(error)</em> Try to be more clearer and succinct with error messages</li> <li><em>(error)</em> Officially adopt <a href="https://rustc-dev-guide.rust-lang.org/diagnostics.html#suggestion-style-guide">an error style guide</a></li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 238c2937a3 |
Bump rustyline from 10.0.0 to 10.1.0 (#2536)
Bumps [rustyline](https://github.com/kkawakam/rustyline) from 10.0.0 to 10.1.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/kkawakam/rustyline/releases">rustyline's releases</a>.</em></p> <blockquote> <h2>10.1.0</h2> <h2>What's Changed</h2> <ul> <li>Upgrade nix dependency</li> <li>Fix ViFirstPrint movement (<a href="https://github-redirect.dependabot.com/kkawakam/rustyline/issues/645">#645</a>)</li> <li>Specify that <code>Editor::iter</code> ends at EOF (Fix <a href="https://github-redirect.dependabot.com/kkawakam/rustyline/issues/647">#647</a>)</li> <li>Optim: do nothing on SIGWINCH if screen size doesn't impact current layout</li> <li>Upgrade skim dependency</li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/kkawakam/rustyline/compare/v10.0.0...v10.1.0">https://github.com/kkawakam/rustyline/compare/v10.0.0...v10.1.0</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | cc79ea3af0 |
Bump prettier from 2.8.2 to 2.8.3 (#2535)
Bumps [prettier](https://github.com/prettier/prettier) from 2.8.2 to 2.8.3. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/prettier/prettier/releases">prettier's releases</a>.</em></p> <blockquote> <h2>2.8.3</h2> <p>Support Angular 15.1</p> <p>🔗 <a href="https://github.com/prettier/prettier/blob/main/CHANGELOG.md#283">Changelog</a></p> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/prettier/prettier/blob/main/CHANGELOG.md">prettier's changelog</a>.</em></p> <blockquote> <h1>2.8.3</h1> <p><a href="https://github.com/prettier/prettier/compare/2.8.2...2.8.3">diff</a></p> <h4>Allow self-closing tags on custom elements (<a href="https://github-redirect.dependabot.com/prettier/prettier/pull/14170">#14170</a> by <a href="https://github.com/fisker"><code>@fisker</code></a>)</h4> <p>See <a href="https://github.com/angular/angular/releases/tag/15.1.0">Angular v15.1.0 release note</a> for details.</p> <!-- raw HTML omitted --> <pre lang="html"><code>// Input <app-test/> <p>// Prettier 2.8.2 SyntaxError: Only void and foreign elements can be self closed "app-test" (1:1) > 1 | <app-test/> | ^^^^^^^^^ 2 |</p> <p>// Prettier 2.8.3 <app-test /> </code></pre></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
Kevin | ff06690140 |
Clarity changes for the VM (#2531)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> Some small changes to the VM with the hopes of making it a bit more clear and concise. It changes the following: - Changes `code` to `code_block` and `code` to `bytecode` in `CallFrame` and `CodeBlock`, respectively. - Adds some creation methods to `CallFrame`. - Implements `Default` for `Vm`. |
2 years ago |
raskad | f52d1d3eb5 |
Recognize Directive Prologues correctly (#2521)
This Pull Request changes the following: - Recognize the `"use strict"` directive prologue correctly. - Refactor parsers to remove a setter function. |
2 years ago |
raskad | 3dca430588 |
Refactor some class features (#2513)
This Pull Request fixes various bugs related to classes. The biggest changes are: - Changed private names to be unique across multiple classes. - Changed private name resolution to work via a visitor after a class is parsed. The way class early errors are defined makes it impossible to perform private name resolution while parsing. - Added function names to class methods. - Added class name binding to method function environments. - Separated opcodes for `static` and non-`static` class method definitions to make the above operations possible. There are still some bugs and further issues with classes but this is already a lot. |
2 years ago |
José Julián Espina | 1bef214a35 |
Prepare `Promises` for new host hooks and job queue API (#2528)
As part of the new modules PR, I was working on implementing the [host hooks](https://tc39.es/ecma262/#sec-host-hooks-summary) for the module import hooks and custom job queues. However, the promises module needed a bit of a refactor in order to couple with the new API. So, I thought it was a good idea to separate the promises refactor into its own PR, since the other PR is already big as it is. - Replaced some usages of `JobCallback` with a new `NativeJob` that isn't traced by the GC, since those closures are always rooted and executed by the `Context` globally. This will also allow hosts to pass their custom jobs to the job queue, and maybe could also accept futures in the Future (pun intended 😆). - Refactored several functions to account for the `HostPromiseRejectionTracker` hook which needs the promise `JsObject`. - Rewrote some patterns with newer Rust idioms. |
2 years ago |
dependabot[bot] | f037a8e685 |
Bump bzip2 from 0.4.3 to 0.4.4 (#2527)
Bumps [bzip2](https://github.com/alexcrichton/bzip2-rs) from 0.4.3 to 0.4.4. <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/alexcrichton/bzip2-rs/commits/0.4.4">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=bzip2&package-manager=cargo&previous-version=0.4.3&new-version=0.4.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/boa-dev/boa/network/alerts). </details> |
2 years ago |
Kevin | 989edd42c7 |
`Break` Opcode and `ByteCompiler` changes (#2523)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> Hi all! 😄 This Pull Request addresses #2424. There are also a few changes made to the `ByteCompiler`, the majority of which are involving `JumpControlInfo`. It changes the following: - Adds `Break` Opcode - Shifts `compile_stmt` into the `statement` module. - Moves `JumpControlInfo` to it's own module. |
2 years ago |
raskad | be9ebc95c0 |
Add regex literal early errors (#2517)
This Pull Request changes the following: - Parse regex literals via `regress` during parsing to return errors in the regex as early syntax errors. |
2 years ago |
dependabot[bot] | 45982effcf |
Bump regex from 1.7.0 to 1.7.1 (#2526)
Bumps [regex](https://github.com/rust-lang/regex) from 1.7.0 to 1.7.1. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/rust-lang/regex/blob/master/CHANGELOG.md">regex's changelog</a>.</em></p> <blockquote> <h1>1.7.1 (2023-01-09)</h1> <p>This release was done principally to try and fix the doc.rs rendering for the regex crate.</p> <p>Performance improvements:</p> <ul> <li>[PERF <a href="https://github-redirect.dependabot.com/rust-lang/regex/issues/930">#930</a>](<a href="https://github-redirect.dependabot.com/rust-lang/regex/pull/930">rust-lang/regex#930</a>): Optimize <code>replacen</code>. This also applies to <code>replace</code>, but not <code>replace_all</code>.</li> </ul> <p>Bug fixes:</p> <ul> <li>[BUG <a href="https://github-redirect.dependabot.com/rust-lang/regex/issues/945">#945</a>](<a href="https://github-redirect.dependabot.com/rust-lang/regex/issues/945">rust-lang/regex#945</a>): Maybe fix rustdoc rendering by just bumping a new release?</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 620dfd623f |
Bump test262 from `f00d411` to `e1048d0` (#2525)
Bumps [test262](https://github.com/tc39/test262) from `f00d411` to `e1048d0`. <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 2ab80e8e00 |
Bump prettier from 2.8.1 to 2.8.2 (#2524)
Bumps [prettier](https://github.com/prettier/prettier) from 2.8.1 to 2.8.2. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/prettier/prettier/releases">prettier's releases</a>.</em></p> <blockquote> <h2>2.8.2</h2> <p>🔗 <a href="https://github.com/prettier/prettier/blob/main/CHANGELOG.md#282">Changelog</a></p> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/prettier/prettier/blob/main/CHANGELOG.md">prettier's changelog</a>.</em></p> <blockquote> <h1>2.8.2</h1> <p><a href="https://github.com/prettier/prettier/compare/2.8.1...2.8.2">diff</a></p> <h4>Don't lowercase link references (<a href="https://github-redirect.dependabot.com/prettier/prettier/pull/13155">#13155</a> by <a href="https://github.com/DerekNonGeneric"><code>@DerekNonGeneric</code></a> & <a href="https://github.com/fisker"><code>@fisker</code></a>)</h4> <!-- raw HTML omitted --> <pre lang="markdown"><code><!-- Input --> We now don't strictly follow the release notes format suggested by [Keep a Changelog]. <p><!-- Prettier 2.8.1 --> We now don't strictly follow the release notes format suggested by <a href="https://example.com/">Keep a Changelog</a>.</p> <p><!-- ^^^^^^^^^^^^^^^^^^ lowercased --></p> <p><!-- Prettier 2.8.2 --> <Same as input> </code></pre></p> <h4>Preserve self-closing tags (<a href="https://github-redirect.dependabot.com/prettier/prettier/pull/13691">#13691</a> by <a href="https://github.com/dcyriller"><code>@dcyriller</code></a>)</h4> <!-- raw HTML omitted --> <pre lang="hbs"><code>{{! Input }} <div /> <div></div> <custom-component /> <custom-component></custom-component> <i /> <i></i> <Component /> <Component></Component> <p>{{! Prettier 2.8.1 }} <div></div> <div></div> <custom-component></custom-component> <custom-component></custom-component> <i></i> <i></i> <Component /> <Component /></p> <p>{{! Prettier 2.8.2 }} </tr></table> </code></pre></p> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
José Julián Espina | edd404ba7f |
Redesign native functions and closures API (#2499)
This PR is a complete redesign of our current native functions and closures API.
I was a bit dissatisfied with our previous design (even though I created it 😆), because it had a lot of superfluous traits, a forced usage of `Gc<GcCell<T>>` and an overly restrictive `NativeObject` bound. This redesign, on the other hand, simplifies a lot our public API, with a simple `NativeCallable` struct that has several constructors for each type of required native function.
This new design doesn't require wrapping every capture type with `Gc<GcCell<T>>`, relaxes the trait requirement to `Trace + 'static` for captures, can be reused in both `JsObject` functions and (soonish) host defined functions, and is (in my opinion) a bit cleaner than the previous iteration. It also offers an `unsafe` API as an escape hatch for users that want to pass non-Copy closures which don't capture traceable types.
Would ask for bikeshedding about the names though, because I don't know if `NativeCallable` is the most precise name for this. Same about the constructor names; I added the `from` prefix to all of them because it's the "standard" practice, but seeing the API doesn't have any other method aside from `call`, it may be better to just remove the prefix altogether.
Let me know what you think :)
|
2 years ago |
raskad | 082d36280b |
Pass a receiver value in property getter opcodes (#2516)
This Pull Request changes the following: - Pass a receiver value to the object `get` function in the `GetPropertyBy*` opcodes. The receiver value may be different from the object, because `ToObject` is not called on it. |
2 years ago |
raskad | f998a1c1ec |
Add early errors for 'eval' or 'arguments' in parameters (#2515)
This Pull Request changes the following: - Add early errors for functions to make sure that 'eval' or 'arguments' cannot be used as binding identifiers in function parameters. When the function body contains a strict directive, this also has to be accounted for. - Fix early errors for function identifiers to make sure they cannot be 'eval' or 'arguments' when a function body contains a strict directive. |
2 years ago |
Veera | 616b7a4513 |
Remove `Literal::Undefined` (#2518)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> This Pull Request fixes/closes #2512 . Removes `Literal::Undefined` so that `undefined` is treated as an identifier name. Ran the parser's idempotency fuzzer and ensured the bug doesn't reproduce. |
2 years ago |
dependabot[bot] | 790877edc4 |
Bump tokio from 1.23.0 to 1.24.1 (#2519)
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.23.0 to 1.24.1. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/tokio-rs/tokio/releases">tokio's releases</a>.</em></p> <blockquote> <h2>Tokio v1.24.1</h2> <p>This release fixes a compilation failure on targets without <code>AtomicU64</code> when using rustc older than 1.63. (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5356">#5356</a>)</p> <p><a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5356">#5356</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5356">tokio-rs/tokio#5356</a></p> <h2>Tokio v1.24.0</h2> <p>The highlight of this release is the reduction of lock contention for all I/O operations (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5300">#5300</a>). We have received reports of up to a 20% improvement in CPU utilization and increased throughput for real-world I/O heavy applications.</p> <h3>Fixed</h3> <ul> <li>rt: improve native <code>AtomicU64</code> support detection (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5284">#5284</a>)</li> </ul> <h3>Added</h3> <ul> <li>rt: add configuration option for max number of I/O events polled from the OS per tick (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5186">#5186</a>)</li> <li>rt: add an environment variable for configuring the default number of worker threads per runtime instance (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/4250">#4250</a>)</li> </ul> <h3>Changed</h3> <ul> <li>sync: reduce MPSC channel stack usage (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5294">#5294</a>)</li> <li>io: reduce lock contention in I/O operations (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5300">#5300</a>)</li> <li>fs: speed up <code>read_dir()</code> by chunking operations (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5309">#5309</a>)</li> <li>rt: use internal <code>ThreadId</code> implementation (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5329">#5329</a>)</li> <li>test: don't auto-advance time when a <code>spawn_blocking</code> task is running (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5115">#5115</a>)</li> </ul> <p><a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5186">#5186</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5186">tokio-rs/tokio#5186</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5294">#5294</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5294">tokio-rs/tokio#5294</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5284">#5284</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5284">tokio-rs/tokio#5284</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/4250">#4250</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/4250">tokio-rs/tokio#4250</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5300">#5300</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5300">tokio-rs/tokio#5300</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5329">#5329</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5329">tokio-rs/tokio#5329</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5115">#5115</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5115">tokio-rs/tokio#5115</a> <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5309">#5309</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5309">tokio-rs/tokio#5309</a></p> <h2>Tokio v1.23.1</h2> <p>This release forward ports changes from 1.18.4.</p> <h3>Fixed</h3> <ul> <li>net: fix Windows named pipe server builder to maintain option when toggling pipe mode (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5336">#5336</a>).</li> </ul> <p><a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/5336">#5336</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/5336">tokio-rs/tokio#5336</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
raskad | 1dcd932f1f |
Fix postfix operator line terminator parsing (#2520)
Postfix increment / decrement operators require that there is no line terminator between the LHS expression and the operator. This was previously ignored. |
2 years ago |
dependabot[bot] | 3d5debac65 |
Bump arbitrary from 1.2.0 to 1.2.2 (#2514)
Bumps [arbitrary](https://github.com/rust-fuzz/arbitrary) from 1.2.0 to 1.2.2. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/rust-fuzz/arbitrary/blob/main/CHANGELOG.md">arbitrary's changelog</a>.</em></p> <blockquote> <h2>1.2.2</h2> <p>Released 2023-01-03.</p> <h3>Fixed</h3> <ul> <li>Ensured that <code>arbitrary</code> and <code>derive_arbitrary</code> versions are synced up so that they don't, e.g., emit generated code that depends on newer versions of <code>arbitrary</code> than the one currently in use. <a href="https://github-redirect.dependabot.com/rust-fuzz/arbitrary/issues/134">#134</a></li> </ul> <h2>1.2.1</h2> <h3>Fixed</h3> <ul> <li>Fixed an issue where <code>std::thread_local!</code> macro invocations in derive code were not fully prefixed, causing confusing build errors in certain situations.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/rust-fuzz/arbitrary/commits">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=arbitrary&package-manager=cargo&previous-version=1.2.0&new-version=1.2.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> |
2 years ago |
dependabot[bot] | 1b04c9eafd |
Bump json5 from 2.2.1 to 2.2.2 (#2511)
Bumps [json5](https://github.com/json5/json5) from 2.2.1 to 2.2.2. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/json5/json5/releases">json5's releases</a>.</em></p> <blockquote> <h2>v2.2.2</h2> <ul> <li>Fix: Properties with the name <code>__proto__</code> are added to objects and arrays. (<a href="https://github-redirect.dependabot.com/json5/json5/issues/199">#199</a>) This also fixes a prototype pollution vulnerability reported by Jonathan Gregson! (<a href="https://github-redirect.dependabot.com/json5/json5/issues/295">#295</a>).</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/json5/json5/blob/main/CHANGELOG.md">json5's changelog</a>.</em></p> <blockquote> <h3>v2.2.2 [<a href="https://github.com/json5/json5/tree/v2.2.2">code</a>, <a href="https://github.com/json5/json5/compare/v2.2.1...v2.2.2">diff</a>]</h3> <ul> <li>Fix: Properties with the name <code>__proto__</code> are added to objects and arrays. (<a href="https://github-redirect.dependabot.com/json5/json5/issues/199">#199</a>) This also fixes a prototype pollution vulnerability reported by Jonathan Gregson! (<a href="https://github-redirect.dependabot.com/json5/json5/issues/295">#295</a>).</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
dependabot[bot] | 5aac69c27d |
Bump once_cell from 1.16.0 to 1.17.0 (#2510)
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.16.0 to 1.17.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/matklad/once_cell/blob/master/CHANGELOG.md">once_cell's changelog</a>.</em></p> <blockquote> <h2>1.17.0</h2> <ul> <li>Add <code>race::OnceRef</code> for storing a <code>&'a T</code>.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href=" |
2 years ago |
Veera | f216a6dda9 |
Fix unary operations on `this` (#2507)
<!--- Thank you for contributing to Boa! Please fill out the template below, and remove or add any information as you feel necessary. ---> This Pull Request fixes/closes #2416. Previously, prefix increment and decrement operations on `this` caused a panic. This PR makes the parser issue a syntax error when the operand UnaryExpression is not simple (as mentioned in https://tc39.es/ecma262/#sec-update-expressions-static-semantics-early-errors). |
2 years ago |