File tree Expand file tree Collapse file tree 4 files changed +9
-5
lines changed
compiler/rustc_target/src/spec Expand file tree Collapse file tree 4 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -1046,7 +1046,7 @@ pub struct TargetOptions {
1046
1046
///
1047
1047
/// Common options are: "unix", "windows". Defaults to no families.
1048
1048
///
1049
- /// See https://doc.rust-lang.org/reference/conditional-compilation.html#target_family
1049
+ /// See < https://doc.rust-lang.org/reference/conditional-compilation.html#target_family>.
1050
1050
pub families : Vec < String > ,
1051
1051
/// Whether the target toolchain's ABI supports returning small structs as an integer.
1052
1052
pub abi_return_struct_as_int : bool ,
Original file line number Diff line number Diff line change @@ -61,6 +61,7 @@ pub fn options() -> TargetOptions {
61
61
62
62
TargetOptions {
63
63
is_like_wasm : true ,
64
+ families : vec ! [ "wasm" . to_string( ) ] ,
64
65
65
66
// we allow dynamic linking, but only cdylibs. Basically we allow a
66
67
// final library artifact that exports some symbols (a wasm module) but
Original file line number Diff line number Diff line change 1
- // run -pass
1
+ // build -pass
2
2
// pretty-expanded FIXME #23616
3
- // ignore-wasm32-bare no target_family
3
+ // ignore-wasm32-bare no bare family
4
4
// ignore-sgx
5
5
6
6
#[ cfg( windows) ]
Original file line number Diff line number Diff line change 1
- // run-pass
2
- // ignore-wasm32-bare no target_family
1
+ // build-pass
3
2
// ignore-sgx
4
3
5
4
// pretty-expanded FIXME #23616
@@ -11,3 +10,7 @@ pub fn main() {
11
10
#[ cfg( target_family = "unix" ) ]
12
11
pub fn main ( ) {
13
12
}
13
+
14
+ #[ cfg( target_family="wasm" ) ]
15
+ pub fn main ( ) {
16
+ }
You can’t perform that action at this time.
0 commit comments