@@ -131,7 +131,8 @@ def stage0_data(rust_root):
131
131
def format_build_time (duration ):
132
132
return str (datetime .timedelta (seconds = int (duration )))
133
133
134
- class RustBuild :
134
+
135
+ class RustBuild (object ):
135
136
def download_stage0 (self ):
136
137
cache_dst = os .path .join (self .build_dir , "cache" )
137
138
rustc_cache = os .path .join (cache_dst , self .stage0_rustc_date ())
@@ -142,7 +143,7 @@ def download_stage0(self):
142
143
os .makedirs (cargo_cache )
143
144
144
145
if self .rustc ().startswith (self .bin_root ()) and \
145
- (not os .path .exists (self .rustc ()) or self .rustc_out_of_date ()):
146
+ (not os .path .exists (self .rustc ()) or self .rustc_out_of_date ()):
146
147
if os .path .exists (self .bin_root ()):
147
148
shutil .rmtree (self .bin_root ())
148
149
channel = self .stage0_rustc_channel ()
@@ -165,7 +166,7 @@ def download_stage0(self):
165
166
f .write (self .stage0_rustc_date ())
166
167
167
168
if self .cargo ().startswith (self .bin_root ()) and \
168
- (not os .path .exists (self .cargo ()) or self .cargo_out_of_date ()):
169
+ (not os .path .exists (self .cargo ()) or self .cargo_out_of_date ()):
169
170
channel = self .stage0_cargo_channel ()
170
171
filename = "cargo-{}-{}.tar.gz" .format (channel , self .build )
171
172
url = "https://static.rust-lang.org/cargo-dist/" + self .stage0_cargo_date ()
@@ -238,8 +239,8 @@ def rustc(self):
238
239
239
240
def get_string (self , line ):
240
241
start = line .find ('"' )
241
- end = start + 1 + line [start + 1 :].find ('"' )
242
- return line [start + 1 :end ]
242
+ end = start + 1 + line [start + 1 :].find ('"' )
243
+ return line [start + 1 :end ]
243
244
244
245
def exe_suffix (self ):
245
246
if sys .platform == 'win32' :
0 commit comments