Merge remote-tracking branch 'mozilla/incoming' into issue-5910-dyna-freeze

Conflicts:
	src/libcore/core.rc
	src/libcore/hashmap.rs
	src/libcore/num/f32.rs
	src/libcore/num/f64.rs
	src/libcore/num/float.rs
	src/libcore/num/int-template.rs
	src/libcore/num/num.rs
	src/libcore/num/strconv.rs
	src/libcore/num/uint-template.rs
	src/libcore/ops.rs
	src/libcore/os.rs
	src/libcore/prelude.rs
	src/libcore/rt/mod.rs
	src/libcore/unstable/lang.rs
	src/librustc/driver/session.rs
	src/librustc/middle/astencode.rs
	src/librustc/middle/borrowck/check_loans.rs
	src/librustc/middle/borrowck/gather_loans.rs
	src/librustc/middle/borrowck/loan.rs
	src/librustc/middle/borrowck/preserve.rs
	src/librustc/middle/liveness.rs
	src/librustc/middle/mem_categorization.rs
	src/librustc/middle/region.rs
	src/librustc/middle/trans/base.rs
	src/librustc/middle/trans/inline.rs
	src/librustc/middle/trans/reachable.rs
	src/librustc/middle/typeck/check/_match.rs
	src/librustc/middle/typeck/check/regionck.rs
	src/librustc/util/ppaux.rs
	src/libstd/arena.rs
	src/libstd/ebml.rs
	src/libstd/json.rs
	src/libstd/serialize.rs
	src/libstd/std.rc
	src/libsyntax/ast_map.rs
	src/libsyntax/parse/parser.rs
	src/test/compile-fail/borrowck-uniq-via-box.rs
	src/test/compile-fail/regions-infer-borrow-scope-within-loop.rs
	src/test/run-pass/borrowck-nested-calls.rs
This commit is contained in:
Niko Matsakis 2013-05-05 15:11:04 -04:00
commit 4300d4d2fa
661 changed files with 7136 additions and 5629 deletions

View file

@ -33,7 +33,7 @@ use syntax::ast::{def_upvar, def_use, def_variant, expr, expr_assign_op};
use syntax::ast::{expr_binary, expr_break, expr_field};
use syntax::ast::{expr_fn_block, expr_index, expr_method_call, expr_path};
use syntax::ast::{def_prim_ty, def_region, def_self, def_ty, def_ty_param};
use syntax::ast::{def_upvar, def_use, def_variant, quot, eq};
use syntax::ast::{def_upvar, def_use, def_variant, div, eq};
use syntax::ast::{expr, expr_again, expr_assign_op};
use syntax::ast::{expr_index, expr_loop};
use syntax::ast::{expr_path, expr_struct, expr_unary, fn_decl};
@ -47,7 +47,7 @@ use syntax::ast::{named_field, ne, neg, node_id, pat, pat_enum, pat_ident};
use syntax::ast::{Path, pat_lit, pat_range, pat_struct};
use syntax::ast::{prim_ty, private, provided};
use syntax::ast::{public, required, rem, self_ty_, shl, shr, stmt_decl};
use syntax::ast::{struct_dtor, struct_field, struct_variant_kind};
use syntax::ast::{struct_field, struct_variant_kind};
use syntax::ast::{sty_static, subtract, trait_ref, tuple_variant_kind, Ty};
use syntax::ast::{ty_bool, ty_char, ty_f, ty_f32, ty_f64, ty_float, ty_i};
use syntax::ast::{ty_i16, ty_i32, ty_i64, ty_i8, ty_int, TyParam, ty_path};
@ -3512,7 +3512,6 @@ pub impl Resolver {
self.resolve_struct(item.id,
generics,
struct_def.fields,
&struct_def.dtor,
visitor);
}
@ -3770,7 +3769,6 @@ pub impl Resolver {
id: node_id,
generics: &Generics,
fields: &[@struct_field],
optional_destructor: &Option<struct_dtor>,
visitor: ResolveVisitor) {
// If applicable, create a rib for the type parameters.
do self.with_type_parameter_rib(HasTypeParameters
@ -3784,23 +3782,6 @@ pub impl Resolver {
for fields.each |field| {
self.resolve_type(field.node.ty, visitor);
}
// Resolve the destructor, if applicable.
match *optional_destructor {
None => {
// Nothing to do.
}
Some(ref destructor) => {
self.resolve_function(NormalRibKind,
None,
NoTypeParameters,
&destructor.node.body,
HasSelfBinding
((*destructor).node.self_id,
true),
visitor);
}
}
}
}
@ -4899,9 +4880,9 @@ pub impl Resolver {
self.add_fixed_trait_for_expr(expr.id,
self.lang_items.mul_trait());
}
expr_binary(quot, _, _) | expr_assign_op(quot, _, _) => {
expr_binary(div, _, _) | expr_assign_op(div, _, _) => {
self.add_fixed_trait_for_expr(expr.id,
self.lang_items.quot_trait());
self.lang_items.div_trait());
}
expr_binary(rem, _, _) | expr_assign_op(rem, _, _) => {
self.add_fixed_trait_for_expr(expr.id,