@@ -436,23 +436,23 @@ fn check_item(ccx: @crate_ctxt, it: @ast::item) {
436
436
do option:: iter ( m_dtor) |dtor| {
437
437
// typecheck the dtor
438
438
check_bare_fn ( ccx, ast_util:: dtor_dec ( ) ,
439
- dtor. node . body , dtor. node . id ,
440
- some ( class_t) ) ;
439
+ dtor. node . body , dtor. node . id ,
440
+ some ( class_t) ) ;
441
441
// Write the dtor's self's type
442
442
write_ty_to_tcx ( tcx, dtor. node . self_id , class_t. self_ty ) ;
443
443
} ;
444
444
445
445
// typecheck the members
446
446
for members. each |m| { check_class_member( ccx, class_t, m) ; }
447
- // Check that there's at least one field
448
- let ( fields, _) = split_class_items( members) ;
449
- if fields. len( ) < 1 u {
450
- ccx. tcx . sess . span_err (
451
- it. span ,
452
- ~"a class must have at least one field") ;
453
- }
454
- // Check that the class is instantiable
455
- check_instantiable ( ccx. tcx , it. span , it. id ) ;
447
+ // Check that there's at least one field
448
+ let ( fields, _) = split_class_items( members) ;
449
+ if fields. len( ) < 1 u {
450
+ ccx. tcx . sess . span_err (
451
+ it. span ,
452
+ ~"a class must have at least one field") ;
453
+ }
454
+ // Check that the class is instantiable
455
+ check_instantiable ( ccx. tcx , it. span , it. id ) ;
456
456
}
457
457
ast:: item_ty ( t, tps) {
458
458
let tpt_ty = ty:: node_id_to_type ( ccx. tcx , it. id ) ;
0 commit comments