File tree Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -1683,12 +1683,7 @@ impl Build {
1683
1683
check_disabled ( ) ?;
1684
1684
1685
1685
if objs. len ( ) <= 1 {
1686
- for obj in objs {
1687
- let mut cmd = self . create_compile_object_cmd ( obj) ?;
1688
- run ( & mut cmd, & self . cargo_output ) ?;
1689
- }
1690
-
1691
- return Ok ( ( ) ) ;
1686
+ return self . compile_objects_sequential ( objs) ;
1692
1687
}
1693
1688
1694
1689
// Limit our parallelism globally with a jobserver.
@@ -1816,10 +1811,7 @@ impl Build {
1816
1811
}
1817
1812
}
1818
1813
1819
- #[ cfg( not( feature = "parallel" ) ) ]
1820
- fn compile_objects ( & self , objs : & [ Object ] ) -> Result < ( ) , Error > {
1821
- check_disabled ( ) ?;
1822
-
1814
+ fn compile_objects_sequential ( & self , objs : & [ Object ] ) -> Result < ( ) , Error > {
1823
1815
for obj in objs {
1824
1816
let mut cmd = self . create_compile_object_cmd ( obj) ?;
1825
1817
run ( & mut cmd, & self . cargo_output ) ?;
@@ -1828,6 +1820,13 @@ impl Build {
1828
1820
Ok ( ( ) )
1829
1821
}
1830
1822
1823
+ #[ cfg( not( feature = "parallel" ) ) ]
1824
+ fn compile_objects ( & self , objs : & [ Object ] ) -> Result < ( ) , Error > {
1825
+ check_disabled ( ) ?;
1826
+
1827
+ self . compile_objects_sequential ( objs)
1828
+ }
1829
+
1831
1830
fn create_compile_object_cmd ( & self , obj : & Object ) -> Result < Command , Error > {
1832
1831
let asm_ext = AsmFileExt :: from_path ( & obj. src ) ;
1833
1832
let is_asm = asm_ext. is_some ( ) ;
You can’t perform that action at this time.
0 commit comments