<!---
Thank you for contributing to Boa! Please fill out the template below, and remove or add any
information as you feel neccesary.
--->
This Pull Request integrates an `ICU4X` data provider API in our codebase, to make use of the internationalization APIs that this crate provides.
It changes the following:
- Creates an API for pluggable icu data providers at `Context` creation, adding an `Icu` struct to store the provider (and some other internationalization tools) at runtime.
- Slightly changes locale related functions to preserve the `Locale` type and ensure correctness. (Will make some other changes related to this).
- Integrates the `sys_locale` crate to fetch the current default locale of an user instead of always returning `en-US`.
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.11.0 to 1.12.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.12.0</h2>
<ul>
<li>Add <code>OnceCell::wait</code>, a blocking variant of <code>get</code>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="9879c77ea0"><code>9879c77</code></a> Merge <a href="https://github-redirect.dependabot.com/matklad/once_cell/issues/179">#179</a></li>
<li><a href="9f43e04e7c"><code>9f43e04</code></a> publish v1.12.0</li>
<li><a href="62b4579811"><code>62b4579</code></a> Merge <a href="https://github-redirect.dependabot.com/matklad/once_cell/issues/177">#177</a></li>
<li><a href="c9351549ee"><code>c935154</code></a> add OnceCell::wait</li>
<li>See full diff in <a href="https://github.com/matklad/once_cell/compare/v1.11.0...v1.12.0">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=once_cell&package-manager=cargo&previous-version=1.11.0&new-version=1.12.0)](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>
The `Context` currently contains a `strict` flag that indicates is global strict mode is active. This is redundant to the strict flag that is set on every function and causes some non spec compliant situations. This pull request removes the strict flag from `Context` and fixes some resulting errors.
Detailed changes:
- Remove strict flag from `Context`
- Make 262 tester compliant with the strict section in [test262/INTERPRETING.md](2e7cdfbe18/INTERPRETING.md (strict-mode))
- Make 262 tester compliant with the `raw` flag in [test262/INTERPRETING.md](2e7cdfbe18/INTERPRETING.md (flags))
- Allow function declarations in strict mode
- Fix parser flag propagation for classes
- Move some early errors from the lexer to the parser
- Add / fix some early errors for 'arguments' and 'eval' identifier usage in strict mode
- Refactor `ArrayLiteral` parser for readability and correct early errors
This Pull Request fixes/closes #2075.
It changes the following:
- Implements a `ProxyBuilder` struct to be able to create `Proxy` objects from native function traps.
- Documents `ProxyBuilder` and adjusts some documentation.
- Fixes a clippy lint.
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.10.0 to 1.11.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>
<h1>Changelog</h1>
<h2>Unreleased</h2>
<ul>
<li></li>
</ul>
<h2>1.11</h2>
<ul>
<li>Add <code>OnceCell::with_value</code> to create initialized <code>OnceCell</code> in <code>const</code> context.</li>
<li>Improve <code>Clone</code> implementation for <code>OnceCell</code>.</li>
<li>Rewrite <code>parking_lot</code> version on top of <code>parking_lot_core</code>, for even smaller cells!</li>
</ul>
<h2>1.10</h2>
<ul>
<li>upgrade <code>parking_lot</code> to <code>0.12.0</code> (note that this bumps MSRV with <code>parking_lot</code> feature enabled to <code>1.49.0</code>).</li>
</ul>
<h2>1.9</h2>
<ul>
<li>Added an <code>atomic-polyfill</code> optional dependency to compile <code>race</code> on platforms without atomics</li>
</ul>
<h2>1.8.0</h2>
<ul>
<li>Add <code>try_insert</code> API -- a version of <code>set</code> that returns a reference.</li>
</ul>
<h2>1.7.2</h2>
<ul>
<li>Improve code size when using parking_lot feature.</li>
</ul>
<h2>1.7.1</h2>
<ul>
<li>Fix <code>race::OnceBox<T></code> to also impl <code>Default</code> even if <code>T</code> doesn't impl <code>Default</code>.</li>
</ul>
<h2>1.7.0</h2>
<ul>
<li>Hide the <code>race</code> module behind (default) <code>race</code> feature.
Turns out that adding <code>race</code> by default was a breaking change on some platforms without atomics.
In this release, we make the module opt-out.
Technically, this is a breaking change for those who use <code>race</code> with <code>no_default_features</code>.
Given that the <code>race</code> module itself only several days old, the breakage is deemed acceptable.</li>
</ul>
<h2>1.6.0</h2>
<ul>
<li>Add <code>Lazy::into_value</code></li>
<li>Stabilize <code>once_cell::race</code> module for "first one wins" no_std-compatible initialization flavor.</li>
<li>Migrate from deprecated <code>compare_and_swap</code> to <code>compare_exchange</code>.</li>
</ul>
<h2>1.5.2</h2>
<ul>
<li><code>OnceBox</code> API uses <code>Box<T></code>.
This a breaking change to unstable API.</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="12f283fd8d"><code>12f283f</code></a> Merge <a href="https://github-redirect.dependabot.com/matklad/once_cell/issues/178">#178</a></li>
<li><a href="443d23c74f"><code>443d23c</code></a> readability</li>
<li><a href="39a47e32d3"><code>39a47e3</code></a> release 1.11.0</li>
<li><a href="5386606ec4"><code>5386606</code></a> fix deadlock</li>
<li><a href="0067580881"><code>0067580</code></a> use exchange_weak</li>
<li><a href="662fcf9784"><code>662fcf9</code></a> replace parking_lot with parking_lot_core</li>
<li><a href="b57c77415b"><code>b57c774</code></a> Merge <a href="https://github-redirect.dependabot.com/matklad/once_cell/issues/175">#175</a></li>
<li><a href="580fb72667"><code>580fb72</code></a> Note that Acquire/Release is necessary in OnceBox</li>
<li><a href="7d45ce0a1e"><code>7d45ce0</code></a> Explain the atomic orderings used in race</li>
<li><a href="090caea92f"><code>090caea</code></a> Merge <a href="https://github-redirect.dependabot.com/matklad/once_cell/issues/170">#170</a></li>
<li>Additional commits viewable in <a href="https://github.com/matklad/once_cell/compare/v1.10.0...v1.11.0">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=once_cell&package-manager=cargo&previous-version=1.10.0&new-version=1.11.0)](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>
This Pull Request adds several helpers to resolve#1562.
It adds the following subroutines:
- toDateTimeOptions
- GetOption
- GetNumberOption
- DefaultNumberOption
This Pull Request fixes/closes #948.
It changes the following:
- Implement the global `eval()` function.
Runtime code evaluation brings some challenges for environments. Currently the setting and getting of variable bindings is done via indices that are calculated at compile time. This prevents costly hashmap lookups at runtime.
Evaluiation at runtime needs access to existing compile time environments. This is a relatively easy change. We wrap compile time environments in `Gc` and make them accessible at runtime.
Because `eval()` can add var bindings to existing function environments, we have to adjust the environments for this. Because we cannot recompile all previously stored binding indices, we have to fallback to hashmap lookups at runtime. To prevent this from tanking our performance we add a flag to each environment that marks if any `eval()` has been executed in that environment (or outer environments). This makes it possible to retain the performance of precompiled environment lookups while having a fallback for `eval()`.
TLDR: `eval()` is not only horribly unsafe but also a burden for performance. [Never use eval()!](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/eval#never_use_eval!)
This Pull Request changes the following:
- Crate dedicated `IdentifierReference` parser and refactor `PrimaryExpression` and `PropertyDefinition` parsers to use it.
- Move `BindingIdentifier` and `LabelIdentifier` parsers from statement parser module to expression parser module to conform with the spec.
- Add and early error case while converting an `ObjectLiteral` to an `ObjectAssignmentPattern`
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.80 to 1.0.81.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/serde-rs/json/releases">serde_json's releases</a>.</em></p>
<blockquote>
<h2>v1.0.81</h2>
<ul>
<li>Work around <code>indexmap</code>/<code>autocfg</code> not always properly detecting whether a <code>std</code> sysroot crate is available (<a href="https://github-redirect.dependabot.com/serde-rs/json/issues/885">#885</a>, thanks <a href="https://github.com/cuviper"><code>@cuviper</code></a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="a0ea9371cd"><code>a0ea937</code></a> Release 1.0.81</li>
<li><a href="6c3dfe948a"><code>6c3dfe9</code></a> Make it clearer that preserve_order implies a std dependency</li>
<li><a href="f34ef95fd1"><code>f34ef95</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/serde-rs/json/issues/885">#885</a> from cuviper/indexmap-std</li>
<li><a href="27939bb1f9"><code>27939bb</code></a> Explicitly enable indexmap/std</li>
<li><a href="c0f93432cc"><code>c0f9343</code></a> Ignore trait_duplication_in_bounds clippy false positives</li>
<li><a href="048a64caec"><code>048a64c</code></a> Resolve type_repetition_in_bounds clippy lint</li>
<li>See full diff in <a href="https://github.com/serde-rs/json/compare/v1.0.80...v1.0.81">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=serde_json&package-manager=cargo&previous-version=1.0.80&new-version=1.0.81)](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>
<!---
Thank you for contributing to Boa! Please fill out the template below, and remove or add any
information as you feel neccesary.
--->
This Pull Request implements ResolveLocale abstract method. It is required for further InitializeDateTimeFormat development.
It changes the following:
- Adds several helpers to operate with locale extensions
- Adds DefaultLocale placeholder
- Implements BestAvailableLocale and locale matchers
- Implements UnicodeExtensionsComponents
- Introduces testing
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/serde-rs/serde/releases">serde's releases</a>.</em></p>
<blockquote>
<h2>v1.0.137</h2>
<ul>
<li>Update documentation links to some data formats whose repos have moved (<a href="https://github-redirect.dependabot.com/serde-rs/serde/issues/2201">#2201</a>, thanks <a href="https://github.com/atouchet"><code>@atouchet</code></a>)</li>
<li>Fix declared <code>rust-version</code> of serde and serde_test (<a href="https://github-redirect.dependabot.com/serde-rs/serde/issues/2168">#2168</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="17c3c0cf86"><code>17c3c0c</code></a> Release 1.0.137</li>
<li><a href="210e6c354e"><code>210e6c3</code></a> Clean up clippy allows which are superseded by msrv in clippy.toml</li>
<li><a href="41823a96df"><code>41823a9</code></a> Ignore more type_repetition_in_bounds</li>
<li><a href="7ca13ff240"><code>7ca13ff</code></a> Ignore type_repetition_in_bounds lint that is incompatible with msrv</li>
<li><a href="52391fd868"><code>52391fd</code></a> Inform clippy of supported compiler version in clippy.toml</li>
<li><a href="9b2d8dfc6b"><code>9b2d8df</code></a> Add a miri test job in CI</li>
<li><a href="07ba7ea8dd"><code>07ba7ea</code></a> Update workflows to actions/checkout@v3</li>
<li><a href="9f29f6bb4a"><code>9f29f6b</code></a> Disable expandtest on miri</li>
<li><a href="f6c104fd1d"><code>f6c104f</code></a> Ignore unused ignore attribute warning in some configurations</li>
<li><a href="8a3a6fb101"><code>8a3a6fb</code></a> Disable ui test on miri</li>
<li>Additional commits viewable in <a href="https://github.com/serde-rs/serde/compare/v1.0.136...v1.0.137">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=serde&package-manager=cargo&previous-version=1.0.136&new-version=1.0.137)](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>
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.79 to 1.0.80.
<details>
<summary>Commits</summary>
<ul>
<li><a href="585e4c5dc7"><code>585e4c5</code></a> Release 1.0.80</li>
<li><a href="52a9c050f5"><code>52a9c05</code></a> Pull miri from miri branch of dtolnay/rust-toolchain</li>
<li><a href="aff685b8c9"><code>aff685b</code></a> Drop unneeded quoting from env variable in workflows yaml</li>
<li><a href="6995bbf784"><code>6995bbf</code></a> Update workflows to actions/checkout@v3</li>
<li><a href="829175e606"><code>829175e</code></a> Fix dev dependencies on serde's derive feature</li>
<li><a href="2733e635b3"><code>2733e63</code></a> Rewrap readme to 80 columns</li>
<li><a href="c5475a32db"><code>c5475a3</code></a> Apply readme changes from PR 864 to crate-level rustdoc</li>
<li><a href="56cf16f900"><code>56cf16f</code></a> Merge pull request 864 from novedevo/patch-1</li>
<li><a href="16b68b06d6"><code>16b68b0</code></a> Tweak grammar to improve readability</li>
<li>See full diff in <a href="https://github.com/serde-rs/json/compare/v1.0.79...v1.0.80">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=serde_json&package-manager=cargo&previous-version=1.0.79&new-version=1.0.80)](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>
It changes the following:
- The current `JsString` implementation has a lot of duplicate heap allocations. For static strings, `JsString` only needs to store the index of `CONSTANTS_ARRAY`. ~~I let `JsString` can store pointer to heap or static area. The two are distinguished by the first bit. (This implementation is rough, maybe we should put flag into `Inner`, like [arcstr](70ba2fac19/src/arc_str.rs (L751-L757)))~~
- I also added more string constants, which are always used.
This PR adds `JsFunction` wrapper around JavaScript `Function` object, like #1746
With this PR we can distinguish between regular object and function object when we need, such as accessors (because they always need to be functions), predicates in `JsArray` methods like `map`, `find`, etc. With this abstraction we leverage the type system of rust which cleans the API making intentions clear.
It changes the following:
- Make methods that take predicate/callback function take `JsFunction`s
- Make `.accessor()` and `.static_accessor()` take `Option<JsFunction>`
- Make `FunctionBuilder` return `JsFunction`
- Make `ConstructorBuilder` return `JsFunction`
- Make `ClassBuilder` return `JsFunction`
This Pull Request changes the following:
- Implement redeclaration errors in the parser
- Remove redeclaration errors from the compiler (this is a big step towards #1907)
- Fix some failing tests on the way
This requires a slight change in our public api. The Parser new requires a full `Context` instead of just the `Interner` for parsing new code. This is required, because if multiple scripts are parsed (e.g. every input in the REPL) global variables must be checked for redeclarations.
<!---
Thank you for contributing to Boa! Please fill out the template below, and remove or add any
information as you feel neccesary.
--->
This Pull Request provides initial implementation for DateTimeFormat constructor. It relates to #1562.
It changes the following:
- Adds `Intl.DateTimeFormat` property
- Partially implements `DateTimeFormat` constructor (`InitializeDateTimeFormat` step is postponed).
- Introduces `ObjectData::DateTimeFormat`
It changes the following:
- `Symbol` object has `[[Construct]]` internal method
- Fix and comment step 1 in `Symbol` constructor.
- Implement step 1 in `BigInt` constructor.
This Pull Request fixes a faulty cast for `Array.splice`.
Negative values for delete_count were being directly casted to usize, which was not the intended behavior. This pull request fixes the issue by using a fallible conversion, defaulting to 0 if the conversion fails.
It changes the following:
- Replace cast in `Array.splice` prototype method with fallible conversion.
This Pull Request changes the following:
- Remove syntax error for unicode escaped characters in keywords from the lexer.
- Adjust the lexer tokens for keywords to indicate if they contain unicode escaped characters.
- Throw syntax errors in parser, when keywords cannot contain unicode escaped characters.
This Pull Request changes the following:
- Allow `Initializer` after `ArrayBindingPattern` in `FormalParameter`
- Refactor `Initializer` detection in `FormalParameter` to avoid clones
This Pull Request changes the following:
- Allow `PropertyName`s in `BindingProperty`in `ObjectBindingPattern`. Previously only `BindingIdentifier`s where allowed.
This Pull Request supersedes #2018 and #2017.
It changes the following:
- Updates the wasm-bindgen dependency now that a new version without the clippy bug has been released
- Updates all dependencies to their latest versions
`ArrayBuffer.isView()` should check whether the object contains a `[[ViewedArrayBuffer]]` internal slot, which `DataView` has.
It changes the following:
- Fix `ArrayBuffer.isView()`
This Pull Request fixes/closes #337.
It changes the following:
- Implement class declaration parsing.
- Implement class expression parsing.
- Implement class execution.
There are still some features like `super` missing and there are some early errors that are not implemented yet. But I think it makes sense to merge this, as we can branch out the missing features from here.
This Pull Request fixes `byteLength` for `ArrayBuffer`. It should be an accessor property rather than a method, per the spec.
It changes the following:
- Removes `byteLength` method for `ArrayBuffer` built-in.
- Add `byteLength` accessor property for `ArrayBuffer`.
- Change `byte_length` function name to `get_byte_length`, to match other function names used for accessor properties.
<!---
Thank you for contributing to Boa! Please fill out the template below, and remove or add any
information as you feel neccesary.
--->
This Pull Request fixes/closes #1989.
It changes the following:
- Implements From<f32> for JsValue
Acked-by: Taylor Sutton <tsutton125@gmail.com>
This Pull Request fixes/closes #1998
The call to retrieve operands modifies pc, setting it to the index of
the *next* instruction. So, we save its initial value and use that
for printing.
Bumps [indexmap](https://github.com/bluss/indexmap) from 1.8.0 to 1.8.1.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/bluss/indexmap/blob/master/RELEASES.md">indexmap's changelog</a>.</em></p>
<blockquote>
<ul>
<li>
<p>1.8.1</p>
<ul>
<li>The new <code>IndexSet::replace_full</code> will return the index of the item along
with the replaced value, if any, by <a href="https://github.com/zakcutner"><code>@zakcutner</code></a> in PR <a href="https://github-redirect.dependabot.com/bluss/indexmap/pull/222">222</a>.</li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="275379c489"><code>275379c</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/bluss/indexmap/issues/222">#222</a> from zakcutner/replace-full</li>
<li><a href="12162abeb0"><code>12162ab</code></a> Release 1.8.1</li>
<li><a href="feb816c4b8"><code>feb816c</code></a> Add a <code>replace_full</code> method on <code>IndexSet</code></li>
<li><a href="d6a9dd6c91"><code>d6a9dd6</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/bluss/indexmap/issues/218">#218</a> from erickt/miri</li>
<li><a href="4dd6619b4c"><code>4dd6619</code></a> Add miri builder</li>
<li><a href="10ee11e56c"><code>10ee11e</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/bluss/indexmap/issues/216">#216</a> from cuviper/dev-dependencies</li>
<li><a href="98de9abe37"><code>98de9ab</code></a> Update dev-dependencies</li>
<li>See full diff in <a href="https://github.com/bluss/indexmap/compare/1.8.0...1.8.1">compare view</a></li>
</ul>
</details>
<br />
[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=indexmap&package-manager=cargo&previous-version=1.8.0&new-version=1.8.1)](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>
This Pull Request lets true/false/null be used as object property identifiers, when using dot assignment.
`foo.null = 'bar';`
It changes the following:
- AST parsing of member expressions
This Pull Request fixes length properties on multiple array prototype methods that were including rest parameters in the count. More tests should pass.
It changes the following:
- Length properties on some array prototype methods
This Pull Request makes the non-octal-decimal-integer test pass. The test would previously fail for values with multiple leading zeroes.
It changes the following:
- Number lexer
`Node::DoWhileLoop` ast node had a buggy bytecode generation where `self.patch_jump(exit)` was called after emitting `LoopEnd` opcode. This would patch the loop exit to the instruction following the do while code, which would panic in cases where do while was enclosed in a block statement.
This Pull Request fixes#1929.
It changes the following:
- Patch jump before emitting `Opcode::LoopEnd`
- Add test which has do while statement inside a block statement to demonstrate that the change fixes the panic.
This Pull Request fixes/closes #1962.
It changes the following:
- When executing arithmetic operations on `JsValue`s, try to use integer operations and fallback to `f64` operations on error.
- Adds tests for serde_json conversions from integer operations.