Add one more webkit-specific whitelist in web-sys (#1865)

* Add one more webkit-specific whitelist in web-sys

* Run rustfmt
This commit is contained in:
Alex Crichton 2019-11-21 09:30:08 -06:00 committed by GitHub
parent db9d603c8f
commit aa461c363b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 5 deletions

View File

@ -465,10 +465,12 @@ impl<'a> Context<'a> {
};
let default_module_path = match self.config.mode {
OutputMode::Web => "\
OutputMode::Web => {
"\
if (typeof module === 'undefined') {
module = import.meta.url.replace(/\\.js$/, '_bg.wasm');
}",
}"
}
_ => "",
};

View File

@ -206,7 +206,7 @@ fn empty_interface_types() {
r#"
#[no_mangle]
pub extern fn foo() {}
"#
"#,
)
.file(
"Cargo.toml",

View File

@ -130,7 +130,7 @@ impl Task {
// resources associated with the future ASAP.
Poll::Ready(()) => {
*borrow = None;
},
}
// Unlike `singlethread.rs` we are responsible for ensuring there's
// a closure to handle the notification that a Future is ready. In

View File

@ -568,7 +568,7 @@ impl<'src> FirstPassRecord<'src> {
// whitelist a few names that have known polyfills
match name {
"AudioContext" => {
"AudioContext" | "OfflineAudioContext" => {
import_type
.vendor_prefixes
.push(Ident::new("webkit", Span::call_site()));