@@ -942,6 +942,7 @@ define_config! {
942942 jobs: Option <u32 > = "jobs" ,
943943 compiletest_diff_tool: Option <String > = "compiletest-diff-tool" ,
944944 ccache: Option <StringOrBool > = "ccache" ,
945+ exclude: Option <Vec <PathBuf >> = "exclude" ,
945946 }
946947}
947948
@@ -1372,22 +1373,6 @@ impl Config {
13721373 "flags.exclude" = ?flags. exclude
13731374 ) ;
13741375
1375- config. skip = flags
1376- . skip
1377- . into_iter ( )
1378- . chain ( flags. exclude )
1379- . map ( |p| {
1380- // Never return top-level path here as it would break `--skip`
1381- // logic on rustc's internal test framework which is utilized
1382- // by compiletest.
1383- if cfg ! ( windows) {
1384- PathBuf :: from ( p. to_str ( ) . unwrap ( ) . replace ( '/' , "\\ " ) )
1385- } else {
1386- p
1387- }
1388- } )
1389- . collect ( ) ;
1390-
13911376 #[ cfg( feature = "tracing" ) ]
13921377 span ! (
13931378 target: "CONFIG_HANDLING" ,
@@ -1632,8 +1617,29 @@ impl Config {
16321617 jobs,
16331618 compiletest_diff_tool,
16341619 mut ccache,
1620+ exclude,
16351621 } = toml. build . unwrap_or_default ( ) ;
16361622
1623+ let mut paths: Vec < PathBuf > = flags. skip . into_iter ( ) . chain ( flags. exclude ) . collect ( ) ;
1624+
1625+ if let Some ( exclude) = exclude {
1626+ paths. extend ( exclude) ;
1627+ }
1628+
1629+ config. skip = paths
1630+ . into_iter ( )
1631+ . map ( |p| {
1632+ // Never return top-level path here as it would break `--skip`
1633+ // logic on rustc's internal test framework which is utilized
1634+ // by compiletest.
1635+ if cfg ! ( windows) {
1636+ PathBuf :: from ( p. to_str ( ) . unwrap ( ) . replace ( '/' , "\\ " ) )
1637+ } else {
1638+ p
1639+ }
1640+ } )
1641+ . collect ( ) ;
1642+
16371643 config. jobs = Some ( threads_from_config ( flags. jobs . unwrap_or ( jobs. unwrap_or ( 0 ) ) ) ) ;
16381644
16391645 if let Some ( file_build) = build {
0 commit comments