File tree 4 files changed +24
-8
lines changed
tests/run-make/core-no-oom-handling
4 files changed +24
-8
lines changed Original file line number Diff line number Diff line change @@ -156,13 +156,20 @@ impl Rustc {
156
156
self
157
157
}
158
158
159
- /// Add a directory to the library search path. Equivalent to `-L`` in rustc.
159
+ /// Add a directory to the library search path. Equivalent to `-L` in rustc.
160
160
pub fn library_search_path < P : AsRef < Path > > ( & mut self , path : P ) -> & mut Self {
161
161
self . cmd . arg ( "-L" ) ;
162
162
self . cmd . arg ( path. as_ref ( ) ) ;
163
163
self
164
164
}
165
165
166
+ /// Override the system root. Equivalent to `--sysroot` in rustc.
167
+ pub fn sysroot < P : AsRef < Path > > ( & mut self , path : P ) -> & mut Self {
168
+ self . cmd . arg ( "--sysroot" ) ;
169
+ self . cmd . arg ( path. as_ref ( ) ) ;
170
+ self
171
+ }
172
+
166
173
/// Specify the edition year.
167
174
pub fn edition ( & mut self , edition : & str ) -> & mut Self {
168
175
self . cmd . arg ( "--edition" ) ;
Original file line number Diff line number Diff line change @@ -25,7 +25,6 @@ run-make/compiler-rt-works-on-mingw/Makefile
25
25
run-make/compressed-debuginfo/Makefile
26
26
run-make/const-prop-lint/Makefile
27
27
run-make/const_fn_mir/Makefile
28
- run-make/core-no-oom-handling/Makefile
29
28
run-make/crate-data-smoke/Makefile
30
29
run-make/crate-hash-rustc-version/Makefile
31
30
run-make/crate-name-priority/Makefile
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ // This test checks that the core library can still compile correctly
2
+ // when the no_global_oom_handling feature is turned on.
3
+ // See https://github.com/rust-lang/rust/pull/110649
4
+
5
+ use run_make_support:: { rustc, tmp_dir} ;
6
+
7
+ fn main ( ) {
8
+ rustc ( )
9
+ . edition ( "2021" )
10
+ . arg ( "-Dwarnings" )
11
+ . crate_type ( "rlib" )
12
+ . input ( "../../../library/core/src/lib.rs" )
13
+ . sysroot ( tmp_dir ( ) . join ( "fakeroot" ) ) ;
14
+ . cfg ( "no_global_oom_handling" )
15
+ . run ( ) ;
16
+ }
You can’t perform that action at this time.
0 commit comments