diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-19 09:26:03 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-19 09:26:03 +0000 |
commit | 9918693037dce8aa4bb6f08741b6812923486c18 (patch) | |
tree | 21d2b40bec7e6a7ea664acee056eb3d08e15a1cf /vendor/js-sys | |
parent | Releasing progress-linux version 1.75.0+dfsg1-5~progress7.99u1. (diff) | |
download | rustc-9918693037dce8aa4bb6f08741b6812923486c18.tar.xz rustc-9918693037dce8aa4bb6f08741b6812923486c18.zip |
Merging upstream version 1.76.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'vendor/js-sys')
-rw-r--r-- | vendor/js-sys/.cargo-checksum.json | 2 | ||||
-rw-r--r-- | vendor/js-sys/CHANGELOG.md | 30 | ||||
-rw-r--r-- | vendor/js-sys/Cargo.toml | 14 | ||||
-rw-r--r-- | vendor/js-sys/src/lib.rs | 151 |
4 files changed, 151 insertions, 46 deletions
diff --git a/vendor/js-sys/.cargo-checksum.json b/vendor/js-sys/.cargo-checksum.json index 3db3d058b..acd553c5c 100644 --- a/vendor/js-sys/.cargo-checksum.json +++ b/vendor/js-sys/.cargo-checksum.json @@ -1 +1 @@ -{"files":{"CHANGELOG.md":"3441ebc3918099baefa15652602bb1b2a06e1fc1de9d95e23079ef7b22832fdc","Cargo.toml":"fda82b2c1df8f510ee2268c8ee1c336f8a842f062c6b4f0b6a7a10eae2a8cef6","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"de73c6d7a9d9eac0674770fde362175700676be0dfaee0b22d4c75fdc28b068e","src/Temporal.rs":"6c3745bf5cbfbbaee3fabecd870c50669f7a4f1ee65fc96e2baa8f3e440cfe86","src/lib.rs":"455c34bb3cba6d5abe4ea06145c18533bbc17af892a75714f02a4642c14e98d1","tests/headless.js":"dc0fdafb377cd6aa1415897083bbbf3d53c0ca39fc1691cc1f1fa7c528190491","tests/headless.rs":"f9eb68e88cc40fc81b7afad881fbdf2243d574f4417705226aa2102a71187e60","tests/wasm/Array.js":"c21d3d69f388ed4574fa7670c4a41240d0cfa2a374ed29f32f93069983138c72","tests/wasm/Array.rs":"a72124c18addf94bd5a8c96c2f5ee59ba6f387dff404576a5295b52dda96879d","tests/wasm/ArrayBuffer.rs":"a465e7cf7114e7466eb843f6612e22f00eb070dda15759bf8c62a1a3147a8c8d","tests/wasm/ArrayIterator.rs":"d849e50fbb8ebf6979e962c89210cf278176b15198c37f59cb15337e9c30ffa0","tests/wasm/BigInt.rs":"55a8070545f477acea07aebccad1bfd36bac88202923c357f894d6721046f53e","tests/wasm/Boolean.rs":"a7ce23aac1cb7abb83ad92dfaec751cd89f8e5047043667f6cc37d36bbd8cfc3","tests/wasm/DataView.rs":"31c672e3771a9ab17da801c8cd83650d7c1dd8598bb42fbcb78ea42ad5ab8c77","tests/wasm/Date.rs":"4de15246207a5f4c961f448dd18c743aa4ae45950571c9e4ec948272677bf584","tests/wasm/Error.rs":"3d593bdce1dee56fa2c35c290d499d687cc7f08971f89f7aa5f9b52d73af1546","tests/wasm/EvalError.rs":"638641bdd06bb43cffee89d37cd39ee615fe98d44d4c8278756a798a6593111f","tests/wasm/Function.js":"6c5876f74cf2838823470c4c007089baa17e2b28e4f602b65a4b2bc67073b9d7","tests/wasm/Function.rs":"2ccfd94e301b569d70face86d31843d095380973673a811302fb67d8d58378fe","tests/wasm/Generator.js":"7be85b1acbc2de5c3d9d8d64a396baf8c5a5b111905759315b3b395a22ea49e2","tests/wasm/Generator.rs":"860e51ccd01a06076b713445a2eff27244f5b349211a322aa9e3e8df2e76c8ce","tests/wasm/Intl.rs":"93ffd147882daca4f482aaa6d18d013c854dfd0bd3d7631e6128c91e88612cc2","tests/wasm/Iterator.js":"525d29257a508e0cfcf4aa01dddd522d1dda6f8f968f271802ebd703e6f347d6","tests/wasm/Iterator.rs":"b2ac023d150179c0c3cd54f27f9b2775f62ad519111dc233e9ebbad5e9983193","tests/wasm/JSON.rs":"a8bf63aa9cbc64448ad320d88224f435cd2980f980b1c0da3ff1c8c3a935399e","tests/wasm/JsString.js":"931aedd837c316bd7e1e2d52142a92d663e36b79995e2dde6d91c9d762095c13","tests/wasm/JsString.rs":"6aa441665ee43d84b13ec0b021d4544b5b0bdbe2cee2329cfb8a00770964390b","tests/wasm/Map.rs":"022b4c26387190e36726b493615f9852ce40ed0c86a97db85bcf06e9086925f2","tests/wasm/MapIterator.rs":"ed0405dbc9a74885fc3c3614d08d5b7c9da2ad14e4b8d3c5f392ad03e12c61cc","tests/wasm/Math.rs":"0604f28481ac122ee88a5198c2b4f234e3f25e266f73c8e455973d486bcf4768","tests/wasm/Number.js":"a0b161084686deee75588a01834dea2bc12fde317d96bd3a0b73c825db71180f","tests/wasm/Number.rs":"3965a281c43e26659391e02ac7fa76de93ebe582858b53f0ca764e61e922f371","tests/wasm/Object.js":"a8ab74505388012de784b2f62f00a57058632e02a3e4bf70f33fa0e5332ff384","tests/wasm/Object.rs":"c8010cd257ba0a49dc864936104cb19c59f9e7801f5b296d909b772aa1f29fb3","tests/wasm/Promise.rs":"8c62a5c08cb43c60391f94e2d697d8925ba47069e19318a30fa64062ef372c8b","tests/wasm/Proxy.js":"63baac7050190339ed772fed09e4bd1845f34bcc36d7aa40ab2ecf93e9db786a","tests/wasm/Proxy.rs":"02d5ec8e5b781e12cdd96b38e643a4d0f6b725c0c904cc614bc83d829d501035","tests/wasm/RangeError.rs":"00a75d29880f53704c1ede81fb0f5c80efa8528a7c9f75b9f64d25234f74c3a4","tests/wasm/ReferenceError.rs":"47b60df993231f4631de2b9317bc1ac0a968976747f05d9b655dc61bcf2a58b4","tests/wasm/Reflect.js":"e5c43d410802ed45f38bffe60d0313dfcb978ac29a748258e889fbb3efa6d64a","tests/wasm/Reflect.rs":"f8bd8876b6bc1740652d51b6bad948eac7eb49541a08e2fe32a85043f9e0aa65","tests/wasm/RegExp.rs":"f91a9c838921832299185582900df6132dd5263fdcce4cc5342b6a1575d727b7","tests/wasm/Set.rs":"ccd68d9240f52d5129169f999a2d782c29c3e00d77f47521c9c4c3158d4f41cd","tests/wasm/SetIterator.rs":"0ad63f4852adcd91a40ffc1d95bb269e23bc338666acdc85a9516c492d5e1561","tests/wasm/SharedArrayBuffer.js":"6d30cec14dfc5890c8303cd1b81da235bce8a37d730232fc8b0d050f0e1db1b2","tests/wasm/SharedArrayBuffer.rs":"fadefea98f3c61aa5ab04f7f5f182a5f73c3436da39c35e9b48e95e7f57a5100","tests/wasm/Symbol.js":"76c6c15f9fd34ffb7efddc90e898e12be074e9c98e066076a2b46f0554754de2","tests/wasm/Symbol.rs":"ae91d396b867bdfd9fd0c66b8863fb8e5c569886eeec98ae6cbd0ffad1a952a8","tests/wasm/SyntaxError.rs":"526ae9168f4979594e9d44f456e6b2816e38860ebf5937c2c905577aae5be7c0","tests/wasm/Temporal.js":"83312c76bdaa0893b7a6d638ccedb5a3d35f9beeb36977e608a739a81a2f4460","tests/wasm/Temporal.rs":"36423a29a94c0d1a218fe2f34384ddb5ec30c8a812ce8a4635579f0d61496b17","tests/wasm/TypeError.rs":"618530b6556daad348106bd1c48c6dd808f54fe4efb344b15238db4ec3254d9f","tests/wasm/TypedArray.rs":"daaa2eb6336ad3868db6cc27846f2c1c7bac542585236efaee23defb20818002","tests/wasm/UriError.rs":"2e695b4823e8875aa72c41aa6679e4d3f924adf47b763cb4462cf96ecdacfda6","tests/wasm/WeakMap.rs":"930498b116924eda0d40ea11c73adbfc049ffd0f11e259f1faf29e090eeea853","tests/wasm/WeakSet.rs":"59c80b6ac0f60fe8499884ee4842b8a4f12039c6c29c58a329e85c187d42c94c","tests/wasm/WebAssembly.js":"5870c3811c8c17bab0b0e14c5ed62af987b8fa52382572a27cf704cded30f061","tests/wasm/WebAssembly.rs":"7d1ed7efb9fc8d052eea2c589a5f3e22f93933c67987b312bbf7eeac0a3afa43","tests/wasm/global_fns.rs":"34e12bfd548b8710297087920599d97e31971d142a8b0c4acb5712f71f1213d3","tests/wasm/main.rs":"e07b9a62897df33dba3d0962f403b19574d5cd99cd2e08e316be364c7a73d7e7"},"package":"c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a"}
\ No newline at end of file +{"files":{"CHANGELOG.md":"ced47935f0bc7bb95d90a38fe37cf78ee6e81cb40635fb556012752dc9583e7a","Cargo.toml":"0f72ea563b6d6cbfac19c678457e4d92307bf806e49f529363549784c38143e8","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"378f5840b258e2779c39418f3f2d7b2ba96f1c7917dd6be0713f88305dbda397","README.md":"de73c6d7a9d9eac0674770fde362175700676be0dfaee0b22d4c75fdc28b068e","src/Temporal.rs":"6c3745bf5cbfbbaee3fabecd870c50669f7a4f1ee65fc96e2baa8f3e440cfe86","src/lib.rs":"5ee5bc3370f921ef11976cd2e6466eb2db723fad875764d3ed4865c4db17d296","tests/headless.js":"dc0fdafb377cd6aa1415897083bbbf3d53c0ca39fc1691cc1f1fa7c528190491","tests/headless.rs":"f9eb68e88cc40fc81b7afad881fbdf2243d574f4417705226aa2102a71187e60","tests/wasm/Array.js":"c21d3d69f388ed4574fa7670c4a41240d0cfa2a374ed29f32f93069983138c72","tests/wasm/Array.rs":"a72124c18addf94bd5a8c96c2f5ee59ba6f387dff404576a5295b52dda96879d","tests/wasm/ArrayBuffer.rs":"a465e7cf7114e7466eb843f6612e22f00eb070dda15759bf8c62a1a3147a8c8d","tests/wasm/ArrayIterator.rs":"d849e50fbb8ebf6979e962c89210cf278176b15198c37f59cb15337e9c30ffa0","tests/wasm/BigInt.rs":"55a8070545f477acea07aebccad1bfd36bac88202923c357f894d6721046f53e","tests/wasm/Boolean.rs":"a7ce23aac1cb7abb83ad92dfaec751cd89f8e5047043667f6cc37d36bbd8cfc3","tests/wasm/DataView.rs":"31c672e3771a9ab17da801c8cd83650d7c1dd8598bb42fbcb78ea42ad5ab8c77","tests/wasm/Date.rs":"4de15246207a5f4c961f448dd18c743aa4ae45950571c9e4ec948272677bf584","tests/wasm/Error.rs":"3d593bdce1dee56fa2c35c290d499d687cc7f08971f89f7aa5f9b52d73af1546","tests/wasm/EvalError.rs":"638641bdd06bb43cffee89d37cd39ee615fe98d44d4c8278756a798a6593111f","tests/wasm/Function.js":"6c5876f74cf2838823470c4c007089baa17e2b28e4f602b65a4b2bc67073b9d7","tests/wasm/Function.rs":"2ccfd94e301b569d70face86d31843d095380973673a811302fb67d8d58378fe","tests/wasm/Generator.js":"7be85b1acbc2de5c3d9d8d64a396baf8c5a5b111905759315b3b395a22ea49e2","tests/wasm/Generator.rs":"860e51ccd01a06076b713445a2eff27244f5b349211a322aa9e3e8df2e76c8ce","tests/wasm/Intl.rs":"93ffd147882daca4f482aaa6d18d013c854dfd0bd3d7631e6128c91e88612cc2","tests/wasm/Iterator.js":"525d29257a508e0cfcf4aa01dddd522d1dda6f8f968f271802ebd703e6f347d6","tests/wasm/Iterator.rs":"b2ac023d150179c0c3cd54f27f9b2775f62ad519111dc233e9ebbad5e9983193","tests/wasm/JSON.rs":"a8bf63aa9cbc64448ad320d88224f435cd2980f980b1c0da3ff1c8c3a935399e","tests/wasm/JsString.js":"931aedd837c316bd7e1e2d52142a92d663e36b79995e2dde6d91c9d762095c13","tests/wasm/JsString.rs":"6aa441665ee43d84b13ec0b021d4544b5b0bdbe2cee2329cfb8a00770964390b","tests/wasm/Map.rs":"022b4c26387190e36726b493615f9852ce40ed0c86a97db85bcf06e9086925f2","tests/wasm/MapIterator.rs":"ed0405dbc9a74885fc3c3614d08d5b7c9da2ad14e4b8d3c5f392ad03e12c61cc","tests/wasm/Math.rs":"0604f28481ac122ee88a5198c2b4f234e3f25e266f73c8e455973d486bcf4768","tests/wasm/Number.js":"a0b161084686deee75588a01834dea2bc12fde317d96bd3a0b73c825db71180f","tests/wasm/Number.rs":"3965a281c43e26659391e02ac7fa76de93ebe582858b53f0ca764e61e922f371","tests/wasm/Object.js":"a8ab74505388012de784b2f62f00a57058632e02a3e4bf70f33fa0e5332ff384","tests/wasm/Object.rs":"c8010cd257ba0a49dc864936104cb19c59f9e7801f5b296d909b772aa1f29fb3","tests/wasm/Promise.rs":"8c62a5c08cb43c60391f94e2d697d8925ba47069e19318a30fa64062ef372c8b","tests/wasm/Proxy.js":"63baac7050190339ed772fed09e4bd1845f34bcc36d7aa40ab2ecf93e9db786a","tests/wasm/Proxy.rs":"02d5ec8e5b781e12cdd96b38e643a4d0f6b725c0c904cc614bc83d829d501035","tests/wasm/RangeError.rs":"00a75d29880f53704c1ede81fb0f5c80efa8528a7c9f75b9f64d25234f74c3a4","tests/wasm/ReferenceError.rs":"47b60df993231f4631de2b9317bc1ac0a968976747f05d9b655dc61bcf2a58b4","tests/wasm/Reflect.js":"e5c43d410802ed45f38bffe60d0313dfcb978ac29a748258e889fbb3efa6d64a","tests/wasm/Reflect.rs":"f8bd8876b6bc1740652d51b6bad948eac7eb49541a08e2fe32a85043f9e0aa65","tests/wasm/RegExp.rs":"f91a9c838921832299185582900df6132dd5263fdcce4cc5342b6a1575d727b7","tests/wasm/Set.rs":"ccd68d9240f52d5129169f999a2d782c29c3e00d77f47521c9c4c3158d4f41cd","tests/wasm/SetIterator.rs":"0ad63f4852adcd91a40ffc1d95bb269e23bc338666acdc85a9516c492d5e1561","tests/wasm/SharedArrayBuffer.js":"6d30cec14dfc5890c8303cd1b81da235bce8a37d730232fc8b0d050f0e1db1b2","tests/wasm/SharedArrayBuffer.rs":"fadefea98f3c61aa5ab04f7f5f182a5f73c3436da39c35e9b48e95e7f57a5100","tests/wasm/Symbol.js":"76c6c15f9fd34ffb7efddc90e898e12be074e9c98e066076a2b46f0554754de2","tests/wasm/Symbol.rs":"ae91d396b867bdfd9fd0c66b8863fb8e5c569886eeec98ae6cbd0ffad1a952a8","tests/wasm/SyntaxError.rs":"526ae9168f4979594e9d44f456e6b2816e38860ebf5937c2c905577aae5be7c0","tests/wasm/Temporal.js":"83312c76bdaa0893b7a6d638ccedb5a3d35f9beeb36977e608a739a81a2f4460","tests/wasm/Temporal.rs":"36423a29a94c0d1a218fe2f34384ddb5ec30c8a812ce8a4635579f0d61496b17","tests/wasm/TypeError.rs":"618530b6556daad348106bd1c48c6dd808f54fe4efb344b15238db4ec3254d9f","tests/wasm/TypedArray.rs":"daaa2eb6336ad3868db6cc27846f2c1c7bac542585236efaee23defb20818002","tests/wasm/UriError.rs":"2e695b4823e8875aa72c41aa6679e4d3f924adf47b763cb4462cf96ecdacfda6","tests/wasm/WeakMap.rs":"930498b116924eda0d40ea11c73adbfc049ffd0f11e259f1faf29e090eeea853","tests/wasm/WeakSet.rs":"59c80b6ac0f60fe8499884ee4842b8a4f12039c6c29c58a329e85c187d42c94c","tests/wasm/WebAssembly.js":"5870c3811c8c17bab0b0e14c5ed62af987b8fa52382572a27cf704cded30f061","tests/wasm/WebAssembly.rs":"7d1ed7efb9fc8d052eea2c589a5f3e22f93933c67987b312bbf7eeac0a3afa43","tests/wasm/global_fns.rs":"34e12bfd548b8710297087920599d97e31971d142a8b0c4acb5712f71f1213d3","tests/wasm/main.rs":"e07b9a62897df33dba3d0962f403b19574d5cd99cd2e08e316be364c7a73d7e7"},"package":"cee9c64da59eae3b50095c18d3e74f8b73c0b86d2792824ff01bbce68ba229ca"}
\ No newline at end of file diff --git a/vendor/js-sys/CHANGELOG.md b/vendor/js-sys/CHANGELOG.md index f822008aa..5a4de395e 100644 --- a/vendor/js-sys/CHANGELOG.md +++ b/vendor/js-sys/CHANGELOG.md @@ -2,36 +2,6 @@ -------------------------------------------------------------------------------- -## Unreleased - -Released YYYY-MM-DD. - -### Added - -* TODO (or remove section if none) - -### Changed - -* TODO (or remove section if none) - -### Deprecated - -* TODO (or remove section if none) - -### Removed - -* TODO (or remove section if none) - -### Fixed - -* TODO (or remove section if none) - -### Security - -* TODO (or remove section if none) - --------------------------------------------------------------------------------- - ## 0.2.1 Released 2018-08-13. diff --git a/vendor/js-sys/Cargo.toml b/vendor/js-sys/Cargo.toml index 2036a4c62..79f6e3e51 100644 --- a/vendor/js-sys/Cargo.toml +++ b/vendor/js-sys/Cargo.toml @@ -11,9 +11,9 @@ [package] edition = "2018" -rust-version = "1.56" +rust-version = "1.57" name = "js-sys" -version = "0.3.64" +version = "0.3.66" authors = ["The wasm-bindgen Developers"] description = """ Bindings for all JS global objects and functions in all JS environments like @@ -23,7 +23,7 @@ homepage = "https://rustwasm.github.io/wasm-bindgen/" documentation = "https://docs.rs/js-sys" readme = "./README.md" categories = ["wasm"] -license = "MIT/Apache-2.0" +license = "MIT OR Apache-2.0" repository = "https://github.com/rustwasm/wasm-bindgen/tree/master/crates/js-sys" resolver = "2" @@ -32,16 +32,16 @@ test = false doctest = false [dependencies.wasm-bindgen] -version = "0.2.87" +version = "0.2.89" [target."cfg(target_arch = \"wasm32\")".dev-dependencies.wasm-bindgen-futures] -version = "0.4.37" +version = "0.4.39" [target."cfg(target_arch = \"wasm32\")".dev-dependencies.wasm-bindgen-test] -version = "=0.3.37" +version = "=0.3.39" [target."cfg(target_arch = \"wasm32\")".dev-dependencies.web-sys] -version = "0.3.64" +version = "0.3.66" features = [ "Headers", "Response", diff --git a/vendor/js-sys/src/lib.rs b/vendor/js-sys/src/lib.rs index 576aec1f0..b18faf6ca 100644 --- a/vendor/js-sys/src/lib.rs +++ b/vendor/js-sys/src/lib.rs @@ -28,6 +28,7 @@ use std::mem; use std::str; use std::str::FromStr; +pub use wasm_bindgen; use wasm_bindgen::prelude::*; // When adding new imports: @@ -1147,32 +1148,32 @@ pub mod Atomics { /// Note: This operation only works with a shared `Int32Array` /// and may not be allowed on the main thread. /// - /// You should use `wait_bigint` to operate on a `BigInt64Array` or a `BigUint64Array`. + /// You should use `wait_bigint` to operate on a `BigInt64Array`. /// /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/wait) #[wasm_bindgen(js_namespace = Atomics, catch)] pub fn wait(typed_array: &Int32Array, index: u32, value: i32) -> Result<JsString, JsValue>; /// The static `Atomics.wait()` method verifies that a given - /// position in an `Int32Array` still contains a given value + /// position in an `BigInt64Array` still contains a given value /// and if so sleeps, awaiting a wakeup or a timeout. /// It returns a string which is either "ok", "not-equal", or "timed-out". - /// Note: This operation only works with a shared `Int32Array` + /// Note: This operation only works with a shared `BigInt64Array` /// and may not be allowed on the main thread. /// - /// This method is used to operate on a `BigInt64Array` or a `BigUint64Array`. + /// You should use `wait` to operate on a `Int32Array`. /// /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/wait) #[wasm_bindgen(js_namespace = Atomics, catch, js_name = wait)] pub fn wait_bigint( - typed_array: &Int32Array, + typed_array: &BigInt64Array, index: u32, value: i64, ) -> Result<JsString, JsValue>; /// Like `wait()`, but with timeout /// - /// You should use `wait_with_timeout_bigint` to operate on a `BigInt64Array` or a `BigUint64Array`. + /// You should use `wait_with_timeout_bigint` to operate on a `BigInt64Array`. /// /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/wait) #[wasm_bindgen(js_namespace = Atomics, catch, js_name = wait)] @@ -1185,17 +1186,81 @@ pub mod Atomics { /// Like `wait()`, but with timeout /// - /// This method is used to operate on a `BigInt64Array` or a `BigUint64Array`. + /// You should use `wait_with_timeout` to operate on a `Int32Array`. /// /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/wait) #[wasm_bindgen(js_namespace = Atomics, catch, js_name = wait)] pub fn wait_with_timeout_bigint( - typed_array: &Int32Array, + typed_array: &BigInt64Array, index: u32, value: i64, timeout: f64, ) -> Result<JsString, JsValue>; + /// The static `Atomics.waitAsync()` method verifies that a given position in an + /// `Int32Array` still contains a given value and if so sleeps, awaiting a + /// wakeup or a timeout. It returns an object with two properties. The first + /// property `async` is a boolean which if true indicates that the second + /// property `value` is a promise. If `async` is false then value is a string + /// whether equal to either "not-equal" or "timed-out". + /// Note: This operation only works with a shared `Int32Array` and may be used + /// on the main thread. + /// + /// You should use `wait_async_bigint` to operate on a `BigInt64Array`. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/waitAsync) + #[wasm_bindgen(js_namespace = Atomics, catch, js_name = waitAsync)] + pub fn wait_async( + typed_array: &Int32Array, + index: u32, + value: i32, + ) -> Result<Object, JsValue>; + + /// The static `Atomics.waitAsync()` method verifies that a given position in an + /// `Int32Array` still contains a given value and if so sleeps, awaiting a + /// wakeup or a timeout. It returns an object with two properties. The first + /// property `async` is a boolean which if true indicates that the second + /// property `value` is a promise. If `async` is false then value is a string + /// whether equal to either "not-equal" or "timed-out". + /// Note: This operation only works with a shared `BigInt64Array` and may be used + /// on the main thread. + /// + /// You should use `wait_async` to operate on a `Int32Array`. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/waitAsync) + #[wasm_bindgen(js_namespace = Atomics, catch, js_name = waitAsync)] + pub fn wait_async_bigint( + typed_array: &BigInt64Array, + index: u32, + value: i64, + ) -> Result<Object, JsValue>; + + /// Like `waitAsync()`, but with timeout + /// + /// You should use `wait_async_with_timeout_bigint` to operate on a `BigInt64Array`. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/waitAsync) + #[wasm_bindgen(js_namespace = Atomics, catch, js_name = waitAsync)] + pub fn wait_async_with_timeout( + typed_array: &Int32Array, + index: u32, + value: i32, + timeout: f64, + ) -> Result<Object, JsValue>; + + /// Like `waitAsync()`, but with timeout + /// + /// You should use `wait_async_with_timeout` to operate on a `Int32Array`. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/waitAsync) + #[wasm_bindgen(js_namespace = Atomics, catch, js_name = waitAsync)] + pub fn wait_async_with_timeout_bigint( + typed_array: &BigInt64Array, + index: u32, + value: i64, + timeout: f64, + ) -> Result<Object, JsValue>; + /// The static `Atomics.xor()` method computes a bitwise XOR /// with a given value at a given position in the array, /// and returns the old value at that position. @@ -1533,6 +1598,18 @@ extern "C" { #[wasm_bindgen(constructor)] pub fn new(buffer: &ArrayBuffer, byteOffset: usize, byteLength: usize) -> DataView; + /// The `DataView` view provides a low-level interface for reading and + /// writing multiple number types in an `ArrayBuffer` irrespective of the + /// platform's endianness. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView) + #[wasm_bindgen(constructor)] + pub fn new_with_shared_array_buffer( + buffer: &SharedArrayBuffer, + byteOffset: usize, + byteLength: usize, + ) -> DataView; + /// The ArrayBuffer referenced by this view. Fixed at construction time and thus read only. /// /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/buffer) @@ -4467,6 +4544,64 @@ pub mod WebAssembly { pub fn set(this: &Table, index: u32, function: &Function) -> Result<(), JsValue>; } + // WebAssembly.Tag + #[wasm_bindgen] + extern "C" { + /// The `WebAssembly.Tag()` constructor creates a new `Tag` object + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Tag) + #[wasm_bindgen(js_namespace = WebAssembly, extends = Object, typescript_type = "WebAssembly.Tag")] + #[derive(Clone, Debug, PartialEq, Eq)] + pub type Tag; + + /// The `WebAssembly.Tag()` constructor creates a new `Tag` object + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Tag) + #[wasm_bindgen(constructor, js_namespace = WebAssembly, catch)] + pub fn new(tag_descriptor: &Object) -> Result<Tag, JsValue>; + } + + // WebAssembly.Exception + #[wasm_bindgen] + extern "C" { + /// The `WebAssembly.Exception()` constructor creates a new `Exception` object + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Exception) + #[wasm_bindgen(js_namespace = WebAssembly, extends = Object, typescript_type = "WebAssembly.Exception")] + #[derive(Clone, Debug, PartialEq, Eq)] + pub type Exception; + + /// The `WebAssembly.Exception()` constructor creates a new `Exception` object + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Exception) + #[wasm_bindgen(constructor, js_namespace = WebAssembly, catch)] + pub fn new(tag: &Tag, payload: &Array) -> Result<Exception, JsValue>; + + /// The `WebAssembly.Exception()` constructor creates a new `Exception` object + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Exception) + #[wasm_bindgen(constructor, js_namespace = WebAssembly, catch)] + pub fn new_with_options( + tag: &Tag, + payload: &Array, + options: &Object, + ) -> Result<Exception, JsValue>; + + /// The `is()` prototype method of the `WebAssembly.Exception` can be used to + /// test if the Exception matches a given tag. + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Exception/is) + #[wasm_bindgen(method, js_namespace = WebAssembly)] + pub fn is(this: &Exception, tag: &Tag) -> bool; + + /// The `getArg()` prototype method of the `WebAssembly.Exception` can be used + /// to get the value of a specified item in the exception's data arguments + /// + /// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/Exception/getArg) + #[wasm_bindgen(method, js_namespace = WebAssembly, js_name = getArg, catch)] + pub fn get_arg(this: &Exception, tag: &Tag, index: u32) -> Result<JsValue, JsValue>; + } + // WebAssembly.Global #[wasm_bindgen] extern "C" { |