diff options
| author | Nikita Popov <nikita.ppv@gmail.com> | 2018-11-08 16:22:20 +0100 |
|---|---|---|
| committer | Nikita Popov <nikita.ppv@gmail.com> | 2018-11-08 16:22:20 +0100 |
| commit | 8407612a8d0fa3195fe7d3785be02790979ddf92 (patch) | |
| tree | 53df8d3ddbb2a29b22feafa33217cc30e5a344bd /src/librustc_codegen_llvm | |
| parent | c14bc575d6de85ebd5a71497eb2db103d56c64f5 (diff) | |
| download | rust-8407612a8d0fa3195fe7d3785be02790979ddf92.tar.gz rust-8407612a8d0fa3195fe7d3785be02790979ddf92.zip | |
Disable wasm32 features on emscripten
These are only supported by the native wasm32 backend.
Diffstat (limited to 'src/librustc_codegen_llvm')
| -rw-r--r-- | src/librustc_codegen_llvm/llvm_util.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/librustc_codegen_llvm/llvm_util.rs b/src/librustc_codegen_llvm/llvm_util.rs index 0a80fdddbf9..0e8fb1c28a3 100644 --- a/src/librustc_codegen_llvm/llvm_util.rs +++ b/src/librustc_codegen_llvm/llvm_util.rs @@ -243,7 +243,8 @@ pub fn target_feature_whitelist(sess: &Session) "hexagon" => HEXAGON_WHITELIST, "mips" | "mips64" => MIPS_WHITELIST, "powerpc" | "powerpc64" => POWERPC_WHITELIST, - "wasm32" => WASM_WHITELIST, + // wasm32 on emscripten does not support these target features + "wasm32" if !sess.target.target.options.is_like_emscripten => WASM_WHITELIST, _ => &[], } } |
