@@ -137,40 +137,40 @@ pub fn compile_input(sess: Session,
137
137
control. make_glob_map ,
138
138
|tcx, analysis| {
139
139
140
- {
141
- let state =
142
- CompileState :: state_after_analysis ( input,
143
- & tcx. sess ,
144
- outdir,
145
- & expanded_crate,
146
- tcx. map . krate ( ) ,
147
- & analysis,
148
- tcx,
149
- & lcx) ;
150
- ( control. after_analysis . callback ) ( state) ;
151
-
152
- tcx. sess . abort_if_errors ( ) ;
153
- if control. after_analysis . stop == Compilation :: Stop {
154
- return Err ( ( ) ) ;
155
- }
156
- }
157
-
158
- if log_enabled ! ( :: log:: INFO ) {
159
- println ! ( "Pre-trans" ) ;
160
- tcx. print_debug_stats ( ) ;
161
- }
162
- let trans = phase_4_translate_to_llvm ( tcx, analysis) ;
163
-
164
- if log_enabled ! ( :: log:: INFO ) {
165
- println ! ( "Post-trans" ) ;
166
- tcx. print_debug_stats ( ) ;
167
- }
140
+ {
141
+ let state =
142
+ CompileState :: state_after_analysis ( input,
143
+ & tcx. sess ,
144
+ outdir,
145
+ & expanded_crate,
146
+ tcx. map . krate ( ) ,
147
+ & analysis,
148
+ tcx,
149
+ & lcx) ;
150
+ ( control. after_analysis . callback ) ( state) ;
151
+
152
+ tcx. sess . abort_if_errors ( ) ;
153
+ if control. after_analysis . stop == Compilation :: Stop {
154
+ return Err ( ( ) ) ;
155
+ }
156
+ }
157
+
158
+ if log_enabled ! ( :: log:: INFO ) {
159
+ println ! ( "Pre-trans" ) ;
160
+ tcx. print_debug_stats ( ) ;
161
+ }
162
+ let trans = phase_4_translate_to_llvm ( tcx, analysis) ;
163
+
164
+ if log_enabled ! ( :: log:: INFO ) {
165
+ println ! ( "Post-trans" ) ;
166
+ tcx. print_debug_stats ( ) ;
167
+ }
168
168
169
169
// Discard interned strings as they are no longer required.
170
- token:: get_ident_interner ( ) . clear ( ) ;
170
+ token:: get_ident_interner ( ) . clear ( ) ;
171
171
172
- Ok ( ( outputs, trans) )
173
- } )
172
+ Ok ( ( outputs, trans) )
173
+ } )
174
174
} ;
175
175
176
176
let ( outputs, trans) = if let Ok ( out) = result {
@@ -708,7 +708,7 @@ pub fn phase_3_run_analysis_passes<'tcx, F, R>(sess: &'tcx Session,
708
708
stability:: Index :: new ( krate) ,
709
709
|tcx| {
710
710
711
- // passes are timed inside typeck
711
+ // passes are timed inside typeck
712
712
typeck:: check_crate ( tcx, trait_map) ;
713
713
714
714
time ( time_passes,
@@ -722,7 +722,7 @@ pub fn phase_3_run_analysis_passes<'tcx, F, R>(sess: &'tcx Session,
722
722
external_exports)
723
723
} ) ;
724
724
725
- // Do not move this check past lint
725
+ // Do not move this check past lint
726
726
time ( time_passes, "stability index" , || {
727
727
tcx. stability . borrow_mut ( ) . build ( tcx, krate, & public_items)
728
728
} ) ;
@@ -755,11 +755,11 @@ pub fn phase_3_run_analysis_passes<'tcx, F, R>(sess: &'tcx Session,
755
755
"rvalue checking" ,
756
756
|| middle:: check_rvalues:: check_crate ( tcx, krate) ) ;
757
757
758
- // Avoid overwhelming user with errors if type checking failed.
759
- // I'm not sure how helpful this is, to be honest, but it avoids a
760
- // lot of annoying errors in the compile-fail tests (basically,
761
- // lint warnings and so on -- kindck used to do this abort, but
762
- // kindck is gone now). -nmatsakis
758
+ // Avoid overwhelming user with errors if type checking failed.
759
+ // I'm not sure how helpful this is, to be honest, but it avoids a
760
+ // lot of annoying errors in the compile-fail tests (basically,
761
+ // lint warnings and so on -- kindck used to do this abort, but
762
+ // kindck is gone now). -nmatsakis
763
763
tcx. sess . abort_if_errors ( ) ;
764
764
765
765
let reachable_map =
@@ -787,7 +787,7 @@ pub fn phase_3_run_analysis_passes<'tcx, F, R>(sess: &'tcx Session,
787
787
"lint checking" ,
788
788
|| lint:: check_crate ( tcx, krate, & exported_items) ) ;
789
789
790
- // The above three passes generate errors w/o aborting
790
+ // The above three passes generate errors w/o aborting
791
791
tcx. sess . abort_if_errors ( ) ;
792
792
793
793
f ( tcx,
@@ -859,7 +859,7 @@ pub fn phase_6_link_output(sess: &Session,
859
859
fn escape_dep_filename ( filename : & str ) -> String {
860
860
// Apparently clang and gcc *only* escape spaces:
861
861
// http://llvm.org/klaus/clang/commit/9d50634cfc268ecc9a7250226dd5ca0e945240d4
862
- filename. replace ( " " , "\" )
862
+ filename. replace ( " " , "\\ " )
863
863
}
864
864
865
865
fn write_out_deps ( sess : & Session , outputs : & OutputFilenames , id : & str ) {
@@ -887,8 +887,8 @@ fn write_out_deps(sess: &Session, outputs: &OutputFilenames, id: &str) {
887
887
888
888
let result =
889
889
( || -> io:: Result < ( ) > {
890
- // Build a list of files used to compile the output and
891
- // write Makefile-compatible dependency rules
890
+ // Build a list of files used to compile the output and
891
+ // write Makefile-compatible dependency rules
892
892
let files: Vec < String > = sess. codemap ( )
893
893
. files
894
894
. borrow ( )
@@ -902,9 +902,9 @@ fn write_out_deps(sess: &Session, outputs: &OutputFilenames, id: &str) {
902
902
try!( write ! ( file, "{}: {}\n \n " , path. display( ) , files. join( " " ) ) ) ;
903
903
}
904
904
905
- // Emit a fake target for each input file to the compilation. This
906
- // prevents `make` from spitting out an error if a file is later
907
- // deleted. For more info see #28735
905
+ // Emit a fake target for each input file to the compilation. This
906
+ // prevents `make` from spitting out an error if a file is later
907
+ // deleted. For more info see #28735
908
908
for path in files {
909
909
try!( writeln ! ( file, "{}:" , path) ) ;
910
910
}
0 commit comments