diff --git a/config.toml.example b/config.toml.example index 848147c2974..2e3b714f922 100644 --- a/config.toml.example +++ b/config.toml.example @@ -377,6 +377,7 @@ # but you can also optionally enable the "emscripten" backend for asm.js or # make this an empty array (but that probably won't get too far in the # bootstrap) +# FIXME: remove the obsolete emscripten backend option. #codegen-backends = ["llvm"] # This is the name of the directory in which codegen backends will get installed diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs index b7ce9c7b397..673ce0053ca 100644 --- a/src/bootstrap/test.rs +++ b/src/bootstrap/test.rs @@ -1046,11 +1046,9 @@ impl Step for Compiletest { // Also provide `rust_test_helpers` for the host. builder.ensure(native::TestHelpers { target: compiler.host }); + // As well as the target + builder.ensure(native::TestHelpers { target }); - // wasm32 can't build the test helpers - if !target.contains("wasm32") { - builder.ensure(native::TestHelpers { target }); - } builder.ensure(RemoteCopyLibs { compiler, target }); let mut cmd = builder.tool_cmd(Tool::Compiletest); diff --git a/src/ci/docker/asmjs/Dockerfile b/src/ci/docker/asmjs/Dockerfile index 3abaab6b34e..cbb9b257051 100644 --- a/src/ci/docker/asmjs/Dockerfile +++ b/src/ci/docker/asmjs/Dockerfile @@ -11,7 +11,8 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ cmake \ sudo \ gdb \ - xz-utils + xz-utils \ + bzip2 COPY scripts/emscripten.sh /scripts/ RUN bash /scripts/emscripten.sh @@ -20,28 +21,17 @@ COPY scripts/sccache.sh /scripts/ RUN sh /scripts/sccache.sh ENV PATH=$PATH:/emsdk-portable -ENV PATH=$PATH:/emsdk-portable/clang/e1.38.15_64bit/ -ENV PATH=$PATH:/emsdk-portable/emscripten/1.38.15/ -ENV PATH=$PATH:/emsdk-portable/node/8.9.1_64bit/bin/ -ENV EMSCRIPTEN=/emsdk-portable/emscripten/1.38.15/ -ENV BINARYEN_ROOT=/emsdk-portable/clang/e1.38.15_64bit/binaryen/ +ENV PATH=$PATH:/emsdk-portable/upstream/emscripten/ +ENV PATH=$PATH:/emsdk-portable/node/12.9.1_64bit/bin/ +ENV BINARYEN_ROOT=/emsdk-portable/upstream/ ENV EM_CONFIG=/emsdk-portable/.emscripten ENV TARGETS=asmjs-unknown-emscripten -ENV RUST_CONFIGURE_ARGS --enable-emscripten --disable-optimize-tests +# TODO: Run run-fail, libcore, libstd, etc. once exceptions are enabled +ENV SCRIPT python2.7 ../x.py test --target $TARGETS src/test/ui -ENV SCRIPT python2.7 ../x.py test --target $TARGETS \ - src/test/ui \ - src/test/run-fail \ - src/libstd \ - src/liballoc \ - src/libcore - -# Debug assertions in rustc are largely covered by other builders, and LLVM -# assertions cause this builder to slow down by quite a large amount and don't -# buy us a huge amount over other builders (not sure if we've ever seen an -# asmjs-specific backend assertion trip), so disable assertions for these -# tests. -ENV NO_LLVM_ASSERTIONS=1 +# This is almost identical to the wasm32-unknown-emscripten target, so +# running with assertions again is not useful ENV NO_DEBUG_ASSERTIONS=1 +ENV NO_LLVM_ASSERTIONS=1 diff --git a/src/ci/docker/disabled/wasm32-exp/Dockerfile b/src/ci/docker/disabled/wasm32-exp/Dockerfile deleted file mode 100644 index 420d47b314c..00000000000 --- a/src/ci/docker/disabled/wasm32-exp/Dockerfile +++ /dev/null @@ -1,35 +0,0 @@ -FROM ubuntu:16.04 - -RUN apt-get update && apt-get install -y --no-install-recommends \ - g++ \ - make \ - file \ - curl \ - ca-certificates \ - python \ - git \ - cmake \ - sudo \ - gdb \ - xz-utils \ - jq \ - bzip2 - -# emscripten -COPY scripts/emscripten-wasm.sh /scripts/ -COPY wasm32-exp/node.sh /usr/local/bin/node -RUN bash /scripts/emscripten-wasm.sh - -# cache -COPY scripts/sccache.sh /scripts/ -RUN sh /scripts/sccache.sh - -# env -ENV PATH=/wasm-install/emscripten:/wasm-install/bin:$PATH -ENV EM_CONFIG=/root/.emscripten - -ENV TARGETS=wasm32-experimental-emscripten - -ENV RUST_CONFIGURE_ARGS --experimental-targets=WebAssembly - -ENV SCRIPT python2.7 ../x.py test --target $TARGETS diff --git a/src/ci/docker/disabled/wasm32-exp/node.sh b/src/ci/docker/disabled/wasm32-exp/node.sh deleted file mode 100755 index aa938971c70..00000000000 --- a/src/ci/docker/disabled/wasm32-exp/node.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash - -path="$(dirname $1)" -file="$(basename $1)" - -shift - -cd "$path" -exec /node-v8.0.0-linux-x64/bin/node "$file" "$@" diff --git a/src/ci/docker/disabled/wasm32/Dockerfile b/src/ci/docker/disabled/wasm32/Dockerfile index 0d2bd39303e..5d91691f6ee 100644 --- a/src/ci/docker/disabled/wasm32/Dockerfile +++ b/src/ci/docker/disabled/wasm32/Dockerfile @@ -11,9 +11,9 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ cmake \ sudo \ gdb \ - xz-utils + xz-utils \ + bzip2 -# emscripten COPY scripts/emscripten.sh /scripts/ RUN bash /scripts/emscripten.sh @@ -21,12 +21,12 @@ COPY scripts/sccache.sh /scripts/ RUN sh /scripts/sccache.sh ENV PATH=$PATH:/emsdk-portable -ENV PATH=$PATH:/emsdk-portable/clang/e1.38.15_64bit/ -ENV PATH=$PATH:/emsdk-portable/emscripten/1.38.15/ -ENV PATH=$PATH:/emsdk-portable/node/8.9.1_64bit/bin/ -ENV EMSCRIPTEN=/emsdk-portable/emscripten/1.38.15/ -ENV BINARYEN_ROOT=/emsdk-portable/clang/e1.38.15_64bit/binaryen/ +ENV PATH=$PATH:/emsdk-portable/upstream/emscripten/ +ENV PATH=$PATH:/emsdk-portable/node/12.9.1_64bit/bin/ +ENV BINARYEN_ROOT=/emsdk-portable/upstream/ ENV EM_CONFIG=/emsdk-portable/.emscripten ENV TARGETS=wasm32-unknown-emscripten -ENV SCRIPT python2.7 ../x.py test --target $TARGETS + +# TODO: Run run-fail, libcore, libstd, etc. once exceptions are enabled +ENV SCRIPT python2.7 ../x.py test --target $TARGETS src/test/ui diff --git a/src/ci/docker/scripts/emscripten-wasm.sh b/src/ci/docker/scripts/emscripten-wasm.sh deleted file mode 100644 index e4a93d7a100..00000000000 --- a/src/ci/docker/scripts/emscripten-wasm.sh +++ /dev/null @@ -1,37 +0,0 @@ -set -ex - -hide_output() { - set +x - on_err=" -echo ERROR: An error was encountered with the build. -cat /tmp/build.log -exit 1 -" - trap "$on_err" ERR - bash -c "while true; do sleep 30; echo \$(date) - building ...; done" & - PING_LOOP_PID=$! - $@ &> /tmp/build.log - trap - ERR - kill $PING_LOOP_PID - rm -f /tmp/build.log - set -x -} - -# Download last known good emscripten from WebAssembly waterfall -BUILD=$(curl -fL https://storage.googleapis.com/wasm-llvm/builds/linux/lkgr.json | \ - jq '.build | tonumber') -curl -sL https://storage.googleapis.com/wasm-llvm/builds/linux/$BUILD/wasm-binaries.tbz2 | \ - hide_output tar xvkj - -# node 8 is required to run wasm -cd / -curl -sL https://nodejs.org/dist/v8.0.0/node-v8.0.0-linux-x64.tar.xz | \ - tar -xJ - -# Make emscripten use wasm-ready node and LLVM tools -echo "EMSCRIPTEN_ROOT = '/wasm-install/emscripten'" >> /root/.emscripten -echo "NODE_JS='/usr/local/bin/node'" >> /root/.emscripten -echo "LLVM_ROOT='/wasm-install/bin'" >> /root/.emscripten -echo "BINARYEN_ROOT = '/wasm-install'" >> /root/.emscripten -echo "COMPILER_ENGINE = NODE_JS" >> /root/.emscripten -echo "JS_ENGINES = [NODE_JS]" >> /root/.emscripten diff --git a/src/ci/docker/scripts/emscripten.sh b/src/ci/docker/scripts/emscripten.sh index 47196e89396..9c7a09e227a 100644 --- a/src/ci/docker/scripts/emscripten.sh +++ b/src/ci/docker/scripts/emscripten.sh @@ -17,20 +17,15 @@ exit 1 set -x } -cd / -curl -fL https://mozilla-games.s3.amazonaws.com/emscripten/releases/emsdk-portable.tar.gz | \ - tar -xz - +git clone https://github.com/emscripten-core/emsdk.git /emsdk-portable cd /emsdk-portable -./emsdk update -hide_output ./emsdk install sdk-1.38.15-64bit -./emsdk activate sdk-1.38.15-64bit +hide_output ./emsdk install 1.38.46-upstream +./emsdk activate 1.38.46-upstream # Compile and cache libc source ./emsdk_env.sh echo "main(){}" > a.c HOME=/emsdk-portable/ emcc a.c -HOME=/emsdk-portable/ emcc -s BINARYEN=1 a.c rm -f a.* # Make emsdk usable by any user diff --git a/src/libcore/ffi.rs b/src/libcore/ffi.rs index eda0e7c518c..0ea4187ccd4 100644 --- a/src/libcore/ffi.rs +++ b/src/libcore/ffi.rs @@ -49,8 +49,10 @@ impl fmt::Debug for c_void { /// Basic implementation of a `va_list`. // The name is WIP, using `VaListImpl` for now. #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), - not(target_arch = "x86_64"), not(target_arch = "asmjs")), + not(target_arch = "x86_64")), all(target_arch = "aarch64", target_os = "ios"), + target_arch = "wasm32", + target_arch = "asmjs", windows))] #[repr(transparent)] #[unstable(feature = "c_variadic", @@ -67,8 +69,10 @@ pub struct VaListImpl<'f> { } #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), - not(target_arch = "x86_64"), not(target_arch = "asmjs")), + not(target_arch = "x86_64")), all(target_arch = "aarch64", target_os = "ios"), + target_arch = "wasm32", + target_arch = "asmjs", windows))] #[unstable(feature = "c_variadic", reason = "the `c_variadic` feature has not been properly tested on \ @@ -137,38 +141,6 @@ pub struct VaListImpl<'f> { _marker: PhantomData<&'f mut &'f c_void>, } -/// asm.js ABI implementation of a `va_list`. -// asm.js uses the PNaCl ABI, which specifies that a `va_list` is -// an array of 4 32-bit integers, according to the old PNaCl docs at -// https://web.archive.org/web/20130518054430/https://www.chromium.org/nativeclient/pnacl/bitcode-abi#TOC-Derived-Types -// and clang does the same in `CreatePNaClABIBuiltinVaListDecl` from `lib/AST/ASTContext.cpp` -#[cfg(all(target_arch = "asmjs", not(windows)))] -#[repr(C)] -#[unstable(feature = "c_variadic", - reason = "the `c_variadic` feature has not been properly tested on \ - all supported platforms", - issue = "44930")] -#[lang = "va_list"] -pub struct VaListImpl<'f> { - inner: [crate::mem::MaybeUninit; 4], - _marker: PhantomData<&'f mut &'f c_void>, -} - -#[cfg(all(target_arch = "asmjs", not(windows)))] -#[unstable(feature = "c_variadic", - reason = "the `c_variadic` feature has not been properly tested on \ - all supported platforms", - issue = "44930")] -impl<'f> fmt::Debug for VaListImpl<'f> { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - unsafe { - write!(f, "va_list* [{:#x}, {:#x}, {:#x}, {:#x}]", - self.inner[0].read(), self.inner[1].read(), - self.inner[2].read(), self.inner[3].read()) - } - } -} - /// A wrapper for a `va_list` #[repr(transparent)] #[derive(Debug)] @@ -178,14 +150,18 @@ impl<'f> fmt::Debug for VaListImpl<'f> { issue = "44930")] pub struct VaList<'a, 'f: 'a> { #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), - not(target_arch = "x86_64"), not(target_arch = "asmjs")), + not(target_arch = "x86_64")), all(target_arch = "aarch64", target_os = "ios"), + target_arch = "wasm32", + target_arch = "asmjs", windows))] inner: VaListImpl<'f>, #[cfg(all(any(target_arch = "aarch64", target_arch = "powerpc", - target_arch = "x86_64", target_arch = "asmjs"), + target_arch = "x86_64"), any(not(target_arch = "aarch64"), not(target_os = "ios")), + not(target_arch = "wasm32"), + not(target_arch = "asmjs"), not(windows)))] inner: &'a mut VaListImpl<'f>, @@ -193,8 +169,10 @@ pub struct VaList<'a, 'f: 'a> { } #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), - not(target_arch = "x86_64"), not(target_arch = "asmjs")), + not(target_arch = "x86_64")), all(target_arch = "aarch64", target_os = "ios"), + target_arch = "wasm32", + target_arch = "asmjs", windows))] #[unstable(feature = "c_variadic", reason = "the `c_variadic` feature has not been properly tested on \ @@ -212,8 +190,10 @@ impl<'f> VaListImpl<'f> { } #[cfg(all(any(target_arch = "aarch64", target_arch = "powerpc", - target_arch = "x86_64", target_arch = "asmjs"), + target_arch = "x86_64"), any(not(target_arch = "aarch64"), not(target_os = "ios")), + not(target_arch = "wasm32"), + not(target_arch = "asmjs"), not(windows)))] #[unstable(feature = "c_variadic", reason = "the `c_variadic` feature has not been properly tested on \ diff --git a/src/libcore/hint.rs b/src/libcore/hint.rs index ee4be6c9151..368a2f16b28 100644 --- a/src/libcore/hint.rs +++ b/src/libcore/hint.rs @@ -114,24 +114,8 @@ pub fn black_box(dummy: T) -> T { // this. LLVM's intepretation of inline assembly is that it's, well, a black // box. This isn't the greatest implementation since it probably deoptimizes // more than we want, but it's so far good enough. - #[cfg(not(any( - target_arch = "asmjs", - all( - target_arch = "wasm32", - target_os = "emscripten" - ) - )))] unsafe { asm!("" : : "r"(&dummy)); return dummy; } - - // Not all platforms support inline assembly so try to do something without - // inline assembly which in theory still hinders at least some optimizations - // on those targets. This is the "best effort" scenario. - unsafe { - let ret = crate::ptr::read_volatile(&dummy); - crate::mem::forget(dummy); - ret - } } diff --git a/src/librustc_codegen_llvm/llvm_util.rs b/src/librustc_codegen_llvm/llvm_util.rs index 541d3d98b79..2dce9b04c9e 100644 --- a/src/librustc_codegen_llvm/llvm_util.rs +++ b/src/librustc_codegen_llvm/llvm_util.rs @@ -257,8 +257,7 @@ pub fn target_feature_whitelist(sess: &Session) "hexagon" => HEXAGON_WHITELIST, "mips" | "mips64" => MIPS_WHITELIST, "powerpc" | "powerpc64" => POWERPC_WHITELIST, - // wasm32 on emscripten does not support these target features - "wasm32" if !sess.target.target.options.is_like_emscripten => WASM_WHITELIST, + "wasm32" => WASM_WHITELIST, _ => &[], } } diff --git a/src/librustc_codegen_ssa/back/write.rs b/src/librustc_codegen_ssa/back/write.rs index f1cfac27033..caaa500766d 100644 --- a/src/librustc_codegen_ssa/back/write.rs +++ b/src/librustc_codegen_ssa/back/write.rs @@ -142,15 +142,12 @@ impl ModuleConfig { // Copy what clang does by turning on loop vectorization at O2 and // slp vectorization at O3. Otherwise configure other optimization aspects // of this pass manager builder. - // Turn off vectorization for emscripten, as it's not very well supported. self.vectorize_loop = !sess.opts.cg.no_vectorize_loops && (sess.opts.optimize == config::OptLevel::Default || - sess.opts.optimize == config::OptLevel::Aggressive) && - !sess.target.target.options.is_like_emscripten; + sess.opts.optimize == config::OptLevel::Aggressive); self.vectorize_slp = !sess.opts.cg.no_vectorize_slp && - sess.opts.optimize == config::OptLevel::Aggressive && - !sess.target.target.options.is_like_emscripten; + sess.opts.optimize == config::OptLevel::Aggressive; // Some targets (namely, NVPTX) interact badly with the MergeFunctions // pass. This is because MergeFunctions can generate new function calls diff --git a/src/librustc_target/abi/call/asmjs.rs b/src/librustc_target/abi/call/asmjs.rs deleted file mode 100644 index 92c86372a86..00000000000 --- a/src/librustc_target/abi/call/asmjs.rs +++ /dev/null @@ -1,47 +0,0 @@ -use crate::abi::call::{FnType, ArgType, Uniform}; -use crate::abi::{HasDataLayout, LayoutOf, TyLayout, TyLayoutMethods}; - -// Data layout: e-p:32:32-i64:64-v128:32:128-n32-S128 - -// See the https://github.com/kripken/emscripten-fastcomp-clang repository. -// The class `EmscriptenABIInfo` in `/lib/CodeGen/TargetInfo.cpp` contains the ABI definitions. - -fn classify_ret_ty<'a, Ty, C>(cx: &C, ret: &mut ArgType<'a, Ty>) - where Ty: TyLayoutMethods<'a, C> + Copy, - C: LayoutOf> + HasDataLayout -{ - if ret.layout.is_aggregate() { - if let Some(unit) = ret.layout.homogeneous_aggregate(cx).unit() { - let size = ret.layout.size; - if unit.size == size { - ret.cast_to(Uniform { - unit, - total: size - }); - return; - } - } - - ret.make_indirect(); - } -} - -fn classify_arg_ty(arg: &mut ArgType<'_, Ty>) { - if arg.layout.is_aggregate() { - arg.make_indirect_byval(); - } -} - -pub fn compute_abi_info<'a, Ty, C>(cx: &C, fty: &mut FnType<'a, Ty>) - where Ty: TyLayoutMethods<'a, C> + Copy, - C: LayoutOf> + HasDataLayout -{ - if !fty.ret.is_ignore() { - classify_ret_ty(cx, &mut fty.ret); - } - - for arg in &mut fty.args { - if arg.is_ignore() { continue; } - classify_arg_ty(arg); - } -} diff --git a/src/librustc_target/abi/call/mod.rs b/src/librustc_target/abi/call/mod.rs index bc21113527e..c6853ebd019 100644 --- a/src/librustc_target/abi/call/mod.rs +++ b/src/librustc_target/abi/call/mod.rs @@ -5,7 +5,6 @@ use crate::spec::{self, HasTargetSpec}; mod aarch64; mod amdgpu; mod arm; -mod asmjs; mod hexagon; mod mips; mod mips64; @@ -557,14 +556,6 @@ impl<'a, Ty> FnType<'a, Ty> { "powerpc" => powerpc::compute_abi_info(cx, self), "powerpc64" => powerpc64::compute_abi_info(cx, self), "s390x" => s390x::compute_abi_info(cx, self), - "asmjs" => asmjs::compute_abi_info(cx, self), - "wasm32" => { - if cx.target_spec().llvm_target.contains("emscripten") { - asmjs::compute_abi_info(cx, self) - } else { - wasm32::compute_abi_info(self) - } - } "msp430" => msp430::compute_abi_info(self), "sparc" => sparc::compute_abi_info(cx, self), "sparc64" => sparc64::compute_abi_info(cx, self), @@ -573,6 +564,7 @@ impl<'a, Ty> FnType<'a, Ty> { "hexagon" => hexagon::compute_abi_info(self), "riscv32" => riscv::compute_abi_info(self, 32), "riscv64" => riscv::compute_abi_info(self, 64), + "wasm32" | "asmjs" => wasm32::compute_abi_info(cx, self), a => return Err(format!("unrecognized arch \"{}\" in target specification", a)) } diff --git a/src/librustc_target/abi/call/wasm32.rs b/src/librustc_target/abi/call/wasm32.rs index 1fdcbb8e39b..698da2a3aaa 100644 --- a/src/librustc_target/abi/call/wasm32.rs +++ b/src/librustc_target/abi/call/wasm32.rs @@ -1,16 +1,38 @@ -use crate::abi::call::{FnType, ArgType}; +use crate::abi::call::{FnType, ArgType, Uniform}; +use crate::abi::{HasDataLayout, LayoutOf, TyLayout, TyLayoutMethods}; -fn classify_ret_ty(ret: &mut ArgType<'_, Ty>) { - ret.extend_integer_width_to(32); +fn classify_ret_ty<'a, Ty, C>(cx: &C, ret: &mut ArgType<'a, Ty>) + where Ty: TyLayoutMethods<'a, C> + Copy, + C: LayoutOf> + HasDataLayout +{ + if ret.layout.is_aggregate() { + if let Some(unit) = ret.layout.homogeneous_aggregate(cx).unit() { + let size = ret.layout.size; + if unit.size == size { + ret.cast_to(Uniform { + unit, + total: size + }); + return; + } + } + + ret.make_indirect(); + } } fn classify_arg_ty(arg: &mut ArgType<'_, Ty>) { - arg.extend_integer_width_to(32); + if arg.layout.is_aggregate() { + arg.make_indirect_byval(); + } } -pub fn compute_abi_info(fty: &mut FnType<'_, Ty>) { +pub fn compute_abi_info<'a, Ty, C>(cx: &C, fty: &mut FnType<'a, Ty>) + where Ty: TyLayoutMethods<'a, C> + Copy, + C: LayoutOf> + HasDataLayout +{ if !fty.ret.is_ignore() { - classify_ret_ty(&mut fty.ret); + classify_ret_ty(cx, &mut fty.ret); } for arg in &mut fty.args { diff --git a/src/librustc_target/spec/asmjs_unknown_emscripten.rs b/src/librustc_target/spec/asmjs_unknown_emscripten.rs index 6dc140cf160..e8f9c1f3d61 100644 --- a/src/librustc_target/spec/asmjs_unknown_emscripten.rs +++ b/src/librustc_target/spec/asmjs_unknown_emscripten.rs @@ -1,40 +1,10 @@ -use super::{LinkArgs, LinkerFlavor, Target, TargetOptions}; +use super::{LinkerFlavor, Target, wasm32_unknown_emscripten}; pub fn target() -> Result { - let mut args = LinkArgs::new(); - args.insert(LinkerFlavor::Em, - vec!["-s".to_string(), - "ERROR_ON_UNDEFINED_SYMBOLS=1".to_string(), - "-s".to_string(), - "ABORTING_MALLOC=0".to_string(), - "-s".to_string(), - "WASM=0".to_string()]); - - let opts = TargetOptions { - dynamic_linking: false, - executables: true, - exe_suffix: ".js".to_string(), - linker_is_gnu: true, - allow_asm: false, - obj_is_bitcode: true, - is_like_emscripten: true, - max_atomic_width: Some(32), - post_link_args: args, - target_family: Some("unix".to_string()), - codegen_backend: "emscripten".to_string(), - .. Default::default() - }; - Ok(Target { - llvm_target: "asmjs-unknown-emscripten".to_string(), - target_endian: "little".to_string(), - target_pointer_width: "32".to_string(), - target_c_int_width: "32".to_string(), - target_os: "emscripten".to_string(), - target_env: String::new(), - target_vendor: "unknown".to_string(), - data_layout: "e-p:32:32-i64:64-v128:32:128-n32-S128".to_string(), - arch: "asmjs".to_string(), - linker_flavor: LinkerFlavor::Em, - options: opts, - }) + let mut target = wasm32_unknown_emscripten::target()?; + target.options.post_link_args + .entry(LinkerFlavor::Em) + .or_default() + .extend(vec!["-s".to_string(), "WASM=0".to_string()]); + Ok(target) } diff --git a/src/librustc_target/spec/mod.rs b/src/librustc_target/spec/mod.rs index 25add0cc6a4..cf1a84dec97 100644 --- a/src/librustc_target/spec/mod.rs +++ b/src/librustc_target/spec/mod.rs @@ -462,7 +462,6 @@ supported_targets! { ("wasm32-unknown-emscripten", wasm32_unknown_emscripten), ("wasm32-unknown-unknown", wasm32_unknown_unknown), ("wasm32-wasi", wasm32_wasi), - ("wasm32-experimental-emscripten", wasm32_experimental_emscripten), ("thumbv6m-none-eabi", thumbv6m_none_eabi), ("thumbv7m-none-eabi", thumbv7m_none_eabi), diff --git a/src/librustc_target/spec/wasm32_experimental_emscripten.rs b/src/librustc_target/spec/wasm32_experimental_emscripten.rs deleted file mode 100644 index b802bee25ae..00000000000 --- a/src/librustc_target/spec/wasm32_experimental_emscripten.rs +++ /dev/null @@ -1,44 +0,0 @@ -use super::{LinkArgs, LinkerFlavor, Target, TargetOptions}; - -pub fn target() -> Result { - let mut post_link_args = LinkArgs::new(); - post_link_args.insert(LinkerFlavor::Em, - vec!["-s".to_string(), - "WASM=1".to_string(), - "-s".to_string(), - "ASSERTIONS=1".to_string(), - "-s".to_string(), - "ERROR_ON_UNDEFINED_SYMBOLS=1".to_string(), - "-g3".to_string()]); - - let opts = TargetOptions { - dynamic_linking: false, - executables: true, - // Today emcc emits two files - a .js file to bootstrap and - // possibly interpret the wasm, and a .wasm file - exe_suffix: ".js".to_string(), - linker_is_gnu: true, - link_env: vec![("EMCC_WASM_BACKEND".to_string(), "1".to_string())], - allow_asm: false, - obj_is_bitcode: true, - is_like_emscripten: true, - max_atomic_width: Some(32), - post_link_args, - limit_rdylib_exports: false, - target_family: Some("unix".to_string()), - .. Default::default() - }; - Ok(Target { - llvm_target: "wasm32-unknown-unknown".to_string(), - target_endian: "little".to_string(), - target_pointer_width: "32".to_string(), - target_c_int_width: "32".to_string(), - target_os: "emscripten".to_string(), - target_env: String::new(), - target_vendor: "unknown".to_string(), - data_layout: "e-m:e-p:32:32-i64:64-n32:64-S128".to_string(), - arch: "wasm32".to_string(), - linker_flavor: LinkerFlavor::Em, - options: opts, - }) -} diff --git a/src/librustc_target/spec/wasm32_unknown_emscripten.rs b/src/librustc_target/spec/wasm32_unknown_emscripten.rs index e0df36884bf..90f3d2fc52d 100644 --- a/src/librustc_target/spec/wasm32_unknown_emscripten.rs +++ b/src/librustc_target/spec/wasm32_unknown_emscripten.rs @@ -1,45 +1,44 @@ -use super::{LinkArgs, LinkerFlavor, Target, TargetOptions}; +use super::wasm32_base; +use super::{LinkArgs, LinkerFlavor, Target, TargetOptions, PanicStrategy}; pub fn target() -> Result { - // FIXME(nikic) BINARYEN_TRAP_MODE=clamp is needed to avoid trapping in our - // -Zsaturating-float-casts implementation. This can be dropped if/when - // we have native fpto[su]i.sat intrinsics, or the implementation otherwise - // stops relying on non-trapping fpto[su]i. let mut post_link_args = LinkArgs::new(); post_link_args.insert(LinkerFlavor::Em, vec!["-s".to_string(), - "BINARYEN=1".to_string(), - "-s".to_string(), "ERROR_ON_UNDEFINED_SYMBOLS=1".to_string(), "-s".to_string(), - "BINARYEN_TRAP_MODE='clamp'".to_string()]); + "ASSERTIONS=1".to_string(), + "-s".to_string(), + "DISABLE_EXCEPTION_CATCHING=1".to_string(), + // FIXME(tlively): Enable this linker option once libc type errors + // are resolved. See https://github.com/rust-lang/libc/pull/1478. + // "-Wl,--fatal-warnings".to_string(), + ]); let opts = TargetOptions { - dynamic_linking: false, - executables: true, - // Today emcc emits two files - a .js file to bootstrap and - // possibly interpret the wasm, and a .wasm file + // emcc emits two files - a .js file to instantiate the wasm and supply platform + // functionality, and a .wasm file. exe_suffix: ".js".to_string(), + linker: None, linker_is_gnu: true, - allow_asm: false, - obj_is_bitcode: true, is_like_emscripten: true, - max_atomic_width: Some(32), + // FIXME(tlively): Emscripten supports unwinding, but we would have to pass + // -enable-emscripten-cxx-exceptions to LLVM at codegen time and merge + // https://reviews.llvm.org/rG5c3cdef84b82464756bb571c13c31cf7773860c3to use it. + panic_strategy: PanicStrategy::Abort, post_link_args, - limit_rdylib_exports: false, target_family: Some("unix".to_string()), - codegen_backend: "emscripten".to_string(), - .. Default::default() + .. wasm32_base::options() }; Ok(Target { - llvm_target: "asmjs-unknown-emscripten".to_string(), + llvm_target: "wasm32-unknown-emscripten".to_string(), target_endian: "little".to_string(), target_pointer_width: "32".to_string(), target_c_int_width: "32".to_string(), target_os: "emscripten".to_string(), target_env: String::new(), target_vendor: "unknown".to_string(), - data_layout: "e-p:32:32-i64:64-v128:32:128-n32-S128".to_string(), + data_layout: "e-m:e-p:32:32-i64:64-n32:64-S128".to_string(), arch: "wasm32".to_string(), linker_flavor: LinkerFlavor::Em, options: opts, diff --git a/src/librustdoc/clean/cfg.rs b/src/librustdoc/clean/cfg.rs index da3b52afadf..7de2583b9f6 100644 --- a/src/librustdoc/clean/cfg.rs +++ b/src/librustdoc/clean/cfg.rs @@ -360,7 +360,7 @@ impl<'a> fmt::Display for Html<'a> { ("target_arch", Some(arch)) => match &*arch.as_str() { "aarch64" => "AArch64", "arm" => "ARM", - "asmjs" => "asm.js", + "asmjs" => "JavaScript", "mips" => "MIPS", "mips64" => "MIPS-64", "msp430" => "MSP430", diff --git a/src/libstd/sys/unix/fast_thread_local.rs b/src/libstd/sys/unix/fast_thread_local.rs index 952ba40ee87..d7e733b7fa0 100644 --- a/src/libstd/sys/unix/fast_thread_local.rs +++ b/src/libstd/sys/unix/fast_thread_local.rs @@ -10,7 +10,8 @@ // fallback implementation to use as well. // // Due to rust-lang/rust#18804, make sure this is not generic! -#[cfg(any(target_os = "linux", target_os = "fuchsia", target_os = "hermit", target_os = "redox"))] +#[cfg(any(target_os = "linux", target_os = "fuchsia", target_os = "hermit", target_os = "redox", + target_os = "emscripten"))] pub unsafe fn register_dtor(t: *mut u8, dtor: unsafe extern fn(*mut u8)) { use crate::mem; use crate::sys_common::thread_local::register_dtor_fallback; diff --git a/src/test/codegen/no-output-asm-is-volatile.rs b/src/test/codegen/no-output-asm-is-volatile.rs index ad497b25a9e..47b38d29417 100644 --- a/src/test/codegen/no-output-asm-is-volatile.rs +++ b/src/test/codegen/no-output-asm-is-volatile.rs @@ -1,7 +1,5 @@ // compile-flags: -O -// ignore-asmjs - #![feature(asm)] #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-abs.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-abs.rs index acb993d51fb..0a687078cd8 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-abs.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-abs.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-ceil.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-ceil.rs index 58667af7e50..9d47339d163 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-ceil.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-ceil.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-cos.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-cos.rs index affbe17d334..770b2a73037 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-cos.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-cos.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp.rs index 43472d9dece..33c86050666 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp2.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp2.rs index 471d49b7841..f7a8986242d 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp2.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-exp2.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-floor.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-floor.rs index bd8ba8b6cd7..a4070317a62 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-floor.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-floor.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fma.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fma.rs index 8ad9e9004c2..0800a498cb7 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fma.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fma.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fsqrt.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fsqrt.rs index ecffca960da..adc44ffd811 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fsqrt.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-fsqrt.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log.rs index 79e6ed54690..9c236f19636 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log10.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log10.rs index db92a94fca8..a922161affa 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log10.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log10.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log2.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log2.rs index 90d9ec3cedd..9624acb383f 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log2.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-log2.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-minmax.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-minmax.rs index 2761392e6a9..7b9b1aec6c8 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-minmax.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-minmax.rs @@ -1,4 +1,3 @@ -// ignore-emscripten // min-llvm-version 7.0 // compile-flags: -C no-prepopulate-passes diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-pow.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-pow.rs index 1dd2c2ccb83..6639e5d652b 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-pow.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-pow.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-powi.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-powi.rs index 09f31bdd6bb..5e82ea023d8 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-powi.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-powi.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-sin.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-sin.rs index dc87651c2aa..8ca2ca86076 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-float-sin.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-float-sin.rs @@ -1,5 +1,3 @@ -// ignore-emscripten - // compile-flags: -C no-prepopulate-passes #![crate_type = "lib"] diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-gather.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-gather.rs index 3389104219d..3b1f4398f90 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-gather.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-gather.rs @@ -1,4 +1,3 @@ -// ignore-emscripten // ignore-tidy-linelength // compile-flags: -C no-prepopulate-passes diff --git a/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-scatter.rs b/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-scatter.rs index dd0a9801bc5..9fce849e523 100644 --- a/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-scatter.rs +++ b/src/test/codegen/simd-intrinsic/simd-intrinsic-generic-scatter.rs @@ -1,4 +1,3 @@ -// ignore-emscripten // ignore-tidy-linelength // compile-flags: -C no-prepopulate-passes diff --git a/src/test/ui/abi/statics/static-mut-foreign.rs b/src/test/ui/abi/statics/static-mut-foreign.rs index 5d6fa416b98..b30e8f00e40 100644 --- a/src/test/ui/abi/statics/static-mut-foreign.rs +++ b/src/test/ui/abi/statics/static-mut-foreign.rs @@ -5,6 +5,10 @@ // ignore-wasm32-bare no libc to test ffi with +// FIXME: This will work on emscripten once libc is updated to include +// rust-lang/libc/#1478 +// ignore-emscripten libc type mismatch + #![feature(rustc_private)] extern crate libc; diff --git a/src/test/ui/async-await/async-fn-size-moved-locals.rs b/src/test/ui/async-await/async-fn-size-moved-locals.rs index 3ffcbb58595..b63d5408a71 100644 --- a/src/test/ui/async-await/async-fn-size-moved-locals.rs +++ b/src/test/ui/async-await/async-fn-size-moved-locals.rs @@ -7,7 +7,7 @@ // // See issue #59123 for a full explanation. -// ignore-wasm32-bare (sizes don't match) +// ignore-emscripten (sizes don't match) // run-pass // edition:2018 diff --git a/src/test/ui/async-await/issue-60709.rs b/src/test/ui/async-await/issue-60709.rs index 9ee419c4a56..61f6ed1b7b2 100644 --- a/src/test/ui/async-await/issue-60709.rs +++ b/src/test/ui/async-await/issue-60709.rs @@ -3,6 +3,7 @@ // compile-flags: -Copt-level=z -Cdebuginfo=2 --edition=2018 // run-pass +// ignore-asmjs wasm2js does not support source maps yet use std::future::Future; use std::task::Poll; diff --git a/src/test/ui/binding/fn-arg-incomplete-pattern-drop-order.rs b/src/test/ui/binding/fn-arg-incomplete-pattern-drop-order.rs index ea4a9e5afa5..4e0a238c5d4 100644 --- a/src/test/ui/binding/fn-arg-incomplete-pattern-drop-order.rs +++ b/src/test/ui/binding/fn-arg-incomplete-pattern-drop-order.rs @@ -2,7 +2,7 @@ // Check that partially moved from function parameters are dropped after the // named bindings that move from them. -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default use std::{panic, cell::RefCell}; diff --git a/src/test/ui/binding/match-arm-statics.rs b/src/test/ui/binding/match-arm-statics.rs index 5f7e357eeb2..e6d17def147 100644 --- a/src/test/ui/binding/match-arm-statics.rs +++ b/src/test/ui/binding/match-arm-statics.rs @@ -1,6 +1,7 @@ // run-pass #![allow(dead_code)] // compile-flags: -g +// ignore-asmjs wasm2js does not support source maps yet #[derive(PartialEq, Eq)] struct NewBool(bool); diff --git a/src/test/ui/builtin-clone-unwind.rs b/src/test/ui/builtin-clone-unwind.rs index 339bcfa1060..1fd91440a78 100644 --- a/src/test/ui/builtin-clone-unwind.rs +++ b/src/test/ui/builtin-clone-unwind.rs @@ -2,7 +2,7 @@ #![allow(unused_variables)] #![allow(unused_imports)] -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // Test that builtin implementations of `Clone` cleanup everything // in case of unwinding. diff --git a/src/test/ui/catch-unwind-bang.rs b/src/test/ui/catch-unwind-bang.rs index f181991713b..c2c21bca7ef 100644 --- a/src/test/ui/catch-unwind-bang.rs +++ b/src/test/ui/catch-unwind-bang.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default fn worker() -> ! { panic!() diff --git a/src/test/ui/consts/const-int-saturating-arith.rs b/src/test/ui/consts/const-int-saturating-arith.rs index 394d6c17f5a..d0a3eccd177 100644 --- a/src/test/ui/consts/const-int-saturating-arith.rs +++ b/src/test/ui/consts/const-int-saturating-arith.rs @@ -1,5 +1,4 @@ // run-pass -// ignore-emscripten no i128 support #![feature(const_saturating_int_methods)] const INT_U32_NO: u32 = (42 as u32).saturating_add(2); diff --git a/src/test/ui/debuginfo-lto.rs b/src/test/ui/debuginfo-lto.rs index e4beee9e737..43f75b0344b 100644 --- a/src/test/ui/debuginfo-lto.rs +++ b/src/test/ui/debuginfo-lto.rs @@ -7,6 +7,7 @@ // aux-build:debuginfo-lto-aux.rs // compile-flags: -C lto -g // no-prefer-dynamic +// ignore-asmjs wasm2js does not support source maps yet extern crate debuginfo_lto_aux; diff --git a/src/test/ui/drop/dynamic-drop-async.rs b/src/test/ui/drop/dynamic-drop-async.rs index 91063edf0f6..bec86d6465a 100644 --- a/src/test/ui/drop/dynamic-drop-async.rs +++ b/src/test/ui/drop/dynamic-drop-async.rs @@ -5,7 +5,7 @@ // run-pass // edition:2018 -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(slice_patterns)] #![allow(unused)] diff --git a/src/test/ui/drop/dynamic-drop.rs b/src/test/ui/drop/dynamic-drop.rs index 8516bc3d964..7fd3f420a6d 100644 --- a/src/test/ui/drop/dynamic-drop.rs +++ b/src/test/ui/drop/dynamic-drop.rs @@ -2,7 +2,7 @@ #![allow(unused_assignments)] #![allow(unused_variables)] -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(generators, generator_trait, untagged_unions)] #![feature(slice_patterns)] diff --git a/src/test/ui/extern/extern-const.fixed b/src/test/ui/extern/extern-const.fixed index 0eec9fb3ee6..9d96b4f63fb 100644 --- a/src/test/ui/extern/extern-const.fixed +++ b/src/test/ui/extern/extern-const.fixed @@ -5,7 +5,8 @@ // compile. To sidestep this by using one that *is* defined. // run-rustfix -// ignore-wasm32 no external library to link to. +// ignore-wasm32-bare no external library to link to. +// ignore-asmjs wasm2js does not support source maps yet // compile-flags: -g #![feature(rustc_private)] extern crate libc; diff --git a/src/test/ui/extern/extern-const.rs b/src/test/ui/extern/extern-const.rs index ca5d7ddf27e..7cef5b3497b 100644 --- a/src/test/ui/extern/extern-const.rs +++ b/src/test/ui/extern/extern-const.rs @@ -5,7 +5,8 @@ // compile. To sidestep this by using one that *is* defined. // run-rustfix -// ignore-wasm32 no external library to link to. +// ignore-wasm32-bare no external library to link to. +// ignore-asmjs wasm2js does not support source maps yet // compile-flags: -g #![feature(rustc_private)] extern crate libc; diff --git a/src/test/ui/extern/extern-const.stderr b/src/test/ui/extern/extern-const.stderr index 77406be2095..258202b6903 100644 --- a/src/test/ui/extern/extern-const.stderr +++ b/src/test/ui/extern/extern-const.stderr @@ -1,5 +1,5 @@ error: extern items cannot be `const` - --> $DIR/extern-const.rs:15:5 + --> $DIR/extern-const.rs:16:5 | LL | const rust_dbg_static_mut: libc::c_int; | ^^^^^ help: try using a static value: `static` diff --git a/src/test/ui/generator/issue-58888.rs b/src/test/ui/generator/issue-58888.rs index 43b37a9afc2..d42d09d401e 100644 --- a/src/test/ui/generator/issue-58888.rs +++ b/src/test/ui/generator/issue-58888.rs @@ -1,5 +1,6 @@ // run-pass // compile-flags: -g +// ignore-asmjs wasm2js does not support source maps yet #![feature(generators, generator_trait)] diff --git a/src/test/ui/generator/panic-drops.rs b/src/test/ui/generator/panic-drops.rs index 5ac97585f4b..b1a5cc67e86 100644 --- a/src/test/ui/generator/panic-drops.rs +++ b/src/test/ui/generator/panic-drops.rs @@ -1,6 +1,6 @@ // run-pass -// ignore-wasm32-bare compiled as panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(generators, generator_trait)] diff --git a/src/test/ui/generator/panic-safe.rs b/src/test/ui/generator/panic-safe.rs index 5f6778674dc..06c02618019 100644 --- a/src/test/ui/generator/panic-safe.rs +++ b/src/test/ui/generator/panic-safe.rs @@ -1,6 +1,6 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(generators, generator_trait)] diff --git a/src/test/ui/generator/resume-after-return.rs b/src/test/ui/generator/resume-after-return.rs index 71a68ff684a..ab18be58155 100644 --- a/src/test/ui/generator/resume-after-return.rs +++ b/src/test/ui/generator/resume-after-return.rs @@ -1,6 +1,6 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(generators, generator_trait)] diff --git a/src/test/ui/generator/size-moved-locals.rs b/src/test/ui/generator/size-moved-locals.rs index 01db971434b..2864fbb2f3c 100644 --- a/src/test/ui/generator/size-moved-locals.rs +++ b/src/test/ui/generator/size-moved-locals.rs @@ -11,6 +11,7 @@ // edition:2018 // ignore-wasm32 issue #62807 +// ignore-asmjs issue #62807 #![feature(generators, generator_trait)] diff --git a/src/test/ui/intrinsics/intrinsics-integer.rs b/src/test/ui/intrinsics/intrinsics-integer.rs index 0154f049950..bac6c8d872b 100644 --- a/src/test/ui/intrinsics/intrinsics-integer.rs +++ b/src/test/ui/intrinsics/intrinsics-integer.rs @@ -1,5 +1,4 @@ // run-pass -// ignore-emscripten no i128 support #![feature(intrinsics)] diff --git a/src/test/ui/issues/issue-14875.rs b/src/test/ui/issues/issue-14875.rs index a2fd7962458..29e974ad83d 100644 --- a/src/test/ui/issues/issue-14875.rs +++ b/src/test/ui/issues/issue-14875.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare always compiled as panic=abort right now +// ignore-emscripten compiled with panic=abort by default // Check that values are not leaked when a dtor panics (#14875) diff --git a/src/test/ui/issues/issue-24687-embed-debuginfo/main.rs b/src/test/ui/issues/issue-24687-embed-debuginfo/main.rs index 773792c7a3f..f08bcdfe6d1 100644 --- a/src/test/ui/issues/issue-24687-embed-debuginfo/main.rs +++ b/src/test/ui/issues/issue-24687-embed-debuginfo/main.rs @@ -1,6 +1,7 @@ // run-pass // aux-build:issue-24687-lib.rs // compile-flags:-g +// ignore-asmjs wasm2js does not support source maps yet extern crate issue_24687_lib as d; diff --git a/src/test/ui/issues/issue-24945-repeat-dash-opts.rs b/src/test/ui/issues/issue-24945-repeat-dash-opts.rs index cf3834952c6..0f92fc2f7f3 100644 --- a/src/test/ui/issues/issue-24945-repeat-dash-opts.rs +++ b/src/test/ui/issues/issue-24945-repeat-dash-opts.rs @@ -3,6 +3,7 @@ // as options to the compiler. // compile-flags:-g -g -O -O +// ignore-asmjs wasm2js does not support source maps yet fn main() { assert_eq!(1, 1); diff --git a/src/test/ui/issues/issue-26484.rs b/src/test/ui/issues/issue-26484.rs index 3b40b3dd8f0..2a8750d3e43 100644 --- a/src/test/ui/issues/issue-26484.rs +++ b/src/test/ui/issues/issue-26484.rs @@ -1,5 +1,6 @@ // run-pass // compile-flags:-g +// ignore-asmjs wasm2js does not support source maps yet fn helper bool>(_f: F) { print!(""); diff --git a/src/test/ui/issues/issue-29948.rs b/src/test/ui/issues/issue-29948.rs index 8ede8143ea6..5237a2f67bd 100644 --- a/src/test/ui/issues/issue-29948.rs +++ b/src/test/ui/issues/issue-29948.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default use std::panic; diff --git a/src/test/ui/issues/issue-33096.rs b/src/test/ui/issues/issue-33096.rs index f0b472e2fe8..2501e1430b3 100644 --- a/src/test/ui/issues/issue-33096.rs +++ b/src/test/ui/issues/issue-33096.rs @@ -1,5 +1,6 @@ // run-pass // compile-flags: -g +// ignore-asmjs wasm2js does not support source maps yet use std::ops::Deref; diff --git a/src/test/ui/issues/issue-33992.rs b/src/test/ui/issues/issue-33992.rs index 94fccff9fc6..a6b137ba645 100644 --- a/src/test/ui/issues/issue-33992.rs +++ b/src/test/ui/issues/issue-33992.rs @@ -1,7 +1,7 @@ // run-pass // ignore-windows // ignore-macos -// ignore-wasm32-bare common linkage not implemented right now +// ignore-emscripten common linkage not implemented right now #![feature(linkage)] diff --git a/src/test/ui/issues/issue-34569.rs b/src/test/ui/issues/issue-34569.rs index 1f68560509e..88dcdd41138 100644 --- a/src/test/ui/issues/issue-34569.rs +++ b/src/test/ui/issues/issue-34569.rs @@ -1,5 +1,6 @@ // run-pass // compile-flags:-g +// ignore-asmjs wasm2js does not support source maps yet // In this test we just want to make sure that the code below does not lead to // a debuginfo verification assertion during compilation. This was caused by the diff --git a/src/test/ui/issues/issue-36856.rs b/src/test/ui/issues/issue-36856.rs index f2dfaf3dd36..5657ba69f94 100644 --- a/src/test/ui/issues/issue-36856.rs +++ b/src/test/ui/issues/issue-36856.rs @@ -2,6 +2,7 @@ // Regression test for #36856. // compile-flags:-g +// ignore-asmjs wasm2js does not support source maps yet fn g() -> bool { false diff --git a/src/test/ui/issues/issue-42210.rs b/src/test/ui/issues/issue-42210.rs index 318e3099f98..01a5d563639 100644 --- a/src/test/ui/issues/issue-42210.rs +++ b/src/test/ui/issues/issue-42210.rs @@ -2,6 +2,7 @@ // Regression test for #42210. // compile-flags: -g +// ignore-asmjs wasm2js does not support source maps yet trait Foo { fn foo() { } diff --git a/src/test/ui/issues/issue-43853.rs b/src/test/ui/issues/issue-43853.rs index 47c3ab59aa2..2a932db05af 100644 --- a/src/test/ui/issues/issue-43853.rs +++ b/src/test/ui/issues/issue-43853.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default use std::panic; diff --git a/src/test/ui/issues/issue-45731.rs b/src/test/ui/issues/issue-45731.rs index d20c07276a8..5c5ac59873a 100644 --- a/src/test/ui/issues/issue-45731.rs +++ b/src/test/ui/issues/issue-45731.rs @@ -1,6 +1,7 @@ // run-pass #![allow(unused_variables)] // compile-flags:--test -g +// ignore-asmjs wasm2js does not support source maps yet #[cfg(target_os = "macos")] #[test] diff --git a/src/test/ui/issues/issue-46519.rs b/src/test/ui/issues/issue-46519.rs index 461ea2498b0..40c3117f01c 100644 --- a/src/test/ui/issues/issue-46519.rs +++ b/src/test/ui/issues/issue-46519.rs @@ -1,6 +1,8 @@ // run-pass // compile-flags:--test -O +// ignore-emscripten compiled with panic=abort by default + #[test] #[should_panic(expected = "creating inhabited type")] fn test() { diff --git a/src/test/ui/issues/issue-48508.rs b/src/test/ui/issues/issue-48508.rs index 385192b882b..b7aa6422876 100644 --- a/src/test/ui/issues/issue-48508.rs +++ b/src/test/ui/issues/issue-48508.rs @@ -8,6 +8,7 @@ // compile-flags:-g // ignore-pretty issue #37195 +// ignore-asmjs wasm2js does not support source maps yet #![feature(non_ascii_idents)] diff --git a/src/test/ui/issues/issue-49579.rs b/src/test/ui/issues/issue-49579.rs index 79cc107d4fe..767e06c4e90 100644 --- a/src/test/ui/issues/issue-49579.rs +++ b/src/test/ui/issues/issue-49579.rs @@ -1,5 +1,4 @@ // build-pass (FIXME(62277): could be check-pass?) -// ignore-emscripten no i128 support fn fibs(n: u32) -> impl Iterator { (0 .. n) diff --git a/src/test/ui/issues/issue-58463.rs b/src/test/ui/issues/issue-58463.rs index 8ab845366b7..af93f76221d 100644 --- a/src/test/ui/issues/issue-58463.rs +++ b/src/test/ui/issues/issue-58463.rs @@ -1,5 +1,7 @@ // run-pass // compile-flags:-C debuginfo=2 +// ignore-asmjs wasm2js does not support source maps yet + fn foo() -> impl Copy { foo } diff --git a/src/test/ui/iterators/iter-count-overflow-debug.rs b/src/test/ui/iterators/iter-count-overflow-debug.rs index d6612035750..fdd285dcad2 100644 --- a/src/test/ui/iterators/iter-count-overflow-debug.rs +++ b/src/test/ui/iterators/iter-count-overflow-debug.rs @@ -1,6 +1,6 @@ // run-pass // only-32bit too impatient for 2⁶⁴ items -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: -C debug_assertions=yes -C opt-level=3 use std::panic; diff --git a/src/test/ui/iterators/iter-position-overflow-debug.rs b/src/test/ui/iterators/iter-position-overflow-debug.rs index f1eded31702..b578999af8e 100644 --- a/src/test/ui/iterators/iter-position-overflow-debug.rs +++ b/src/test/ui/iterators/iter-position-overflow-debug.rs @@ -1,6 +1,6 @@ // run-pass // only-32bit too impatient for 2⁶⁴ items -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: -C debug_assertions=yes -C opt-level=3 use std::panic; diff --git a/src/test/ui/iterators/iter-step-overflow-debug.rs b/src/test/ui/iterators/iter-step-overflow-debug.rs index 5d67c7cbb42..3872a03b682 100644 --- a/src/test/ui/iterators/iter-step-overflow-debug.rs +++ b/src/test/ui/iterators/iter-step-overflow-debug.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: -C debug_assertions=yes use std::panic; diff --git a/src/test/ui/iterators/iter-sum-overflow-debug.rs b/src/test/ui/iterators/iter-sum-overflow-debug.rs index ee4ab4d24c6..4a9e8cdb72e 100644 --- a/src/test/ui/iterators/iter-sum-overflow-debug.rs +++ b/src/test/ui/iterators/iter-sum-overflow-debug.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: -C debug_assertions=yes use std::panic; diff --git a/src/test/ui/iterators/iter-sum-overflow-overflow-checks.rs b/src/test/ui/iterators/iter-sum-overflow-overflow-checks.rs index 429f8e0bc96..6bd1425e324 100644 --- a/src/test/ui/iterators/iter-sum-overflow-overflow-checks.rs +++ b/src/test/ui/iterators/iter-sum-overflow-overflow-checks.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: -C overflow-checks use std::panic; diff --git a/src/test/ui/macros/macro-comma-behavior-rpass.rs b/src/test/ui/macros/macro-comma-behavior-rpass.rs index 9f1a31d1ae2..1c791bb1ca3 100644 --- a/src/test/ui/macros/macro-comma-behavior-rpass.rs +++ b/src/test/ui/macros/macro-comma-behavior-rpass.rs @@ -13,6 +13,8 @@ // compile-flags: --test -C debug_assertions=yes // revisions: std core +// ignore-emscripten compiled with panic=abort by default + #![cfg_attr(core, no_std)] #[cfg(std)] use std::fmt; diff --git a/src/test/ui/mir/mir_calls_to_shims.rs b/src/test/ui/mir/mir_calls_to_shims.rs index 6f13d5612ce..de8d958af45 100644 --- a/src/test/ui/mir/mir_calls_to_shims.rs +++ b/src/test/ui/mir/mir_calls_to_shims.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![feature(fn_traits)] #![feature(never_type)] diff --git a/src/test/ui/mir/mir_drop_order.rs b/src/test/ui/mir/mir_drop_order.rs index 2949437b1e4..2bc5cf1c976 100644 --- a/src/test/ui/mir/mir_drop_order.rs +++ b/src/test/ui/mir/mir_drop_order.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default use std::cell::RefCell; use std::panic; diff --git a/src/test/ui/numbers-arithmetic/float-int-invalid-const-cast.rs b/src/test/ui/numbers-arithmetic/float-int-invalid-const-cast.rs index d210abdf499..ced3c61ec16 100644 --- a/src/test/ui/numbers-arithmetic/float-int-invalid-const-cast.rs +++ b/src/test/ui/numbers-arithmetic/float-int-invalid-const-cast.rs @@ -1,5 +1,4 @@ // run-pass -// ignore-emscripten no i128 support #![deny(const_err)] diff --git a/src/test/ui/numbers-arithmetic/i128.rs b/src/test/ui/numbers-arithmetic/i128.rs index ea0ef95e4f1..ef558c0aa0c 100644 --- a/src/test/ui/numbers-arithmetic/i128.rs +++ b/src/test/ui/numbers-arithmetic/i128.rs @@ -1,9 +1,6 @@ // run-pass #![allow(overflowing_literals)] -// ignore-emscripten i128 doesn't work - - #![feature(test)] extern crate test; diff --git a/src/test/ui/numbers-arithmetic/next-power-of-two-overflow-debug.rs b/src/test/ui/numbers-arithmetic/next-power-of-two-overflow-debug.rs index e9927304f23..c1959866e5c 100644 --- a/src/test/ui/numbers-arithmetic/next-power-of-two-overflow-debug.rs +++ b/src/test/ui/numbers-arithmetic/next-power-of-two-overflow-debug.rs @@ -1,6 +1,6 @@ // run-pass // compile-flags: -C debug_assertions=yes -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // ignore-emscripten dies with an LLVM error use std::panic; diff --git a/src/test/ui/numbers-arithmetic/u128-as-f32.rs b/src/test/ui/numbers-arithmetic/u128-as-f32.rs index bef7deb6276..2671a267f4a 100644 --- a/src/test/ui/numbers-arithmetic/u128-as-f32.rs +++ b/src/test/ui/numbers-arithmetic/u128-as-f32.rs @@ -1,5 +1,4 @@ // run-pass -// ignore-emscripten u128 not supported #![feature(test)] #![deny(overflowing_literals)] diff --git a/src/test/ui/numbers-arithmetic/u128.rs b/src/test/ui/numbers-arithmetic/u128.rs index 93940716323..0b2305c6e8b 100644 --- a/src/test/ui/numbers-arithmetic/u128.rs +++ b/src/test/ui/numbers-arithmetic/u128.rs @@ -1,6 +1,4 @@ // run-pass -// ignore-emscripten u128 not supported - #![feature(test)] diff --git a/src/test/ui/panic-runtime/transitive-link-a-bunch.rs b/src/test/ui/panic-runtime/transitive-link-a-bunch.rs index 5d72771c2dc..6dcb852a366 100644 --- a/src/test/ui/panic-runtime/transitive-link-a-bunch.rs +++ b/src/test/ui/panic-runtime/transitive-link-a-bunch.rs @@ -4,7 +4,7 @@ // aux-build:wants-panic-runtime-abort.rs // aux-build:panic-runtime-lang-items.rs // error-pattern: is not compiled with this crate's panic strategy `unwind` -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![no_std] #![no_main] diff --git a/src/test/ui/panic-runtime/want-unwind-got-abort.rs b/src/test/ui/panic-runtime/want-unwind-got-abort.rs index 4c25c09d643..e7811d40b5b 100644 --- a/src/test/ui/panic-runtime/want-unwind-got-abort.rs +++ b/src/test/ui/panic-runtime/want-unwind-got-abort.rs @@ -1,7 +1,7 @@ // error-pattern:is incompatible with this crate's strategy of `unwind` // aux-build:panic-runtime-abort.rs // aux-build:panic-runtime-lang-items.rs -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![no_std] #![no_main] diff --git a/src/test/ui/panic-runtime/want-unwind-got-abort2.rs b/src/test/ui/panic-runtime/want-unwind-got-abort2.rs index 478af451e7f..44671796c01 100644 --- a/src/test/ui/panic-runtime/want-unwind-got-abort2.rs +++ b/src/test/ui/panic-runtime/want-unwind-got-abort2.rs @@ -2,7 +2,7 @@ // aux-build:panic-runtime-abort.rs // aux-build:wants-panic-runtime-abort.rs // aux-build:panic-runtime-lang-items.rs -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![no_std] #![no_main] diff --git a/src/test/ui/panic-uninitialized-zeroed.rs b/src/test/ui/panic-uninitialized-zeroed.rs index b0d66295618..72b844d8b48 100644 --- a/src/test/ui/panic-uninitialized-zeroed.rs +++ b/src/test/ui/panic-uninitialized-zeroed.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare always compiled as panic=abort right now and this requires unwinding +// ignore-emscripten compiled with panic=abort by default // This test checks that instantiating an uninhabited type via `mem::{uninitialized,zeroed}` results // in a runtime panic. diff --git a/src/test/ui/proc-macro/expand-with-a-macro.rs b/src/test/ui/proc-macro/expand-with-a-macro.rs index 418178d0f0e..690a76ef3e0 100644 --- a/src/test/ui/proc-macro/expand-with-a-macro.rs +++ b/src/test/ui/proc-macro/expand-with-a-macro.rs @@ -1,7 +1,7 @@ // run-pass // aux-build:expand-with-a-macro.rs -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![deny(warnings)] diff --git a/src/test/ui/reachable-unnameable-items.rs b/src/test/ui/reachable-unnameable-items.rs index f1e53a0d8b4..26c51efea1e 100644 --- a/src/test/ui/reachable-unnameable-items.rs +++ b/src/test/ui/reachable-unnameable-items.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // aux-build:reachable-unnameable-items.rs extern crate reachable_unnameable_items; diff --git a/src/test/ui/rfc-1937-termination-trait/termination-trait-in-test.rs b/src/test/ui/rfc-1937-termination-trait/termination-trait-in-test.rs index 39825c4f9a9..c8e8b9dcfc6 100644 --- a/src/test/ui/rfc-1937-termination-trait/termination-trait-in-test.rs +++ b/src/test/ui/rfc-1937-termination-trait/termination-trait-in-test.rs @@ -1,6 +1,8 @@ // compile-flags: --test // run-pass +// ignore-emscripten compiled with panic=abort by default + #![feature(test)] extern crate test; diff --git a/src/test/ui/rfcs/rfc1857-drop-order.rs b/src/test/ui/rfcs/rfc1857-drop-order.rs index 7923aa7c0e2..b10b6ec11b5 100644 --- a/src/test/ui/rfcs/rfc1857-drop-order.rs +++ b/src/test/ui/rfcs/rfc1857-drop-order.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default #![allow(dead_code, unreachable_code)] diff --git a/src/test/ui/sepcomp/sepcomp-lib-lto.rs b/src/test/ui/sepcomp/sepcomp-lib-lto.rs index 164ae79c254..51a572899f8 100644 --- a/src/test/ui/sepcomp/sepcomp-lib-lto.rs +++ b/src/test/ui/sepcomp/sepcomp-lib-lto.rs @@ -4,6 +4,7 @@ // aux-build:sepcomp_lib.rs // compile-flags: -C lto -g +// ignore-asmjs wasm2js does not support source maps yet // no-prefer-dynamic extern crate sepcomp_lib; diff --git a/src/test/ui/test-attrs/test-allow-fail-attr.rs b/src/test/ui/test-attrs/test-allow-fail-attr.rs index 1a478460efc..55b743ab7c7 100644 --- a/src/test/ui/test-attrs/test-allow-fail-attr.rs +++ b/src/test/ui/test-attrs/test-allow-fail-attr.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: --test #![feature(allow_fail)] diff --git a/src/test/ui/test-attrs/test-should-fail-good-message.rs b/src/test/ui/test-attrs/test-should-fail-good-message.rs index 9fa759f9eb4..2284953fbbe 100644 --- a/src/test/ui/test-attrs/test-should-fail-good-message.rs +++ b/src/test/ui/test-attrs/test-should-fail-good-message.rs @@ -1,5 +1,5 @@ // run-pass -// ignore-wasm32-bare compiled with panic=abort by default +// ignore-emscripten compiled with panic=abort by default // compile-flags: --test #[test] #[should_panic(expected = "foo")] diff --git a/src/test/ui/unboxed-closures/unboxed-closures-unique-type-id.rs b/src/test/ui/unboxed-closures/unboxed-closures-unique-type-id.rs index f86499e2e3f..5d1e00d2d35 100644 --- a/src/test/ui/unboxed-closures/unboxed-closures-unique-type-id.rs +++ b/src/test/ui/unboxed-closures/unboxed-closures-unique-type-id.rs @@ -10,6 +10,7 @@ // This is a regression test for issue #17021. // // compile-flags: -g +// ignore-asmjs wasm2js does not support source maps yet use std::ptr;