Struct rustc::middle::typeck::check::FnCtxt[src]

pub struct FnCtxt<'a> {
    // some fields omitted
}

Methods

impl<'a> FnCtxt<'a>

fn infcx<'b>(&'b self) -> &'b InferCtxt<'a>

fn err_count_since_creation(&self) -> uint

fn vtable_context<'a>(&'a self) -> VtableContext<'a>

impl<'a> FnCtxt<'a>

fn tag(&self) -> String

fn local_ty(&self, span: Span, nid: NodeId) -> t

fn write_ty(&self, node_id: NodeId, ty: t)

fn write_substs(&self, node_id: NodeId, substs: ItemSubsts)

fn write_ty_substs(&self, node_id: NodeId, ty: t, substs: ItemSubsts)

fn write_autoderef_adjustment(&self, node_id: NodeId, derefs: uint)

fn write_adjustment(&self, node_id: NodeId, adj: AutoAdjustment)

fn write_nil(&self, node_id: NodeId)

fn write_bot(&self, node_id: NodeId)

fn write_error(&self, node_id: NodeId)

fn to_ty(&self, ast_t: &Ty) -> t

fn pat_to_str(&self, pat: &Pat) -> String

fn expr_ty(&self, ex: &Expr) -> t

fn node_ty(&self, id: NodeId) -> t

fn method_ty_substs(&self, id: NodeId) -> Substs

fn opt_node_ty_substs(&self, id: NodeId, f: |&ItemSubsts|)

fn mk_subty(&self, a_is_expected: bool, origin: TypeOrigin, sub: t, sup: t) -> Result<(), type_err>

fn can_mk_subty(&self, sub: t, sup: t) -> Result<(), type_err>

fn mk_assignty(&self, expr: &Expr, sub: t, sup: t) -> Result<(), type_err>

fn mk_eqty(&self, a_is_expected: bool, origin: TypeOrigin, sub: t, sup: t) -> Result<(), type_err>

fn mk_subr(&self, a_is_expected: bool, origin: SubregionOrigin, sub: Region, sup: Region)

fn with_region_lb<R>(&self, lb: NodeId, f: || -> R) -> R

fn type_error_message(&self, sp: Span, mk_msg: |String| -> String, actual_ty: t, err: Option<&type_err>)

fn report_mismatched_return_types(&self, sp: Span, e: t, a: t, err: &type_err)

fn report_mismatched_types(&self, sp: Span, e: t, a: t, err: &type_err)

Trait Implementations

impl<'a> ExprTyProvider for FnCtxt<'a>

fn expr_ty(&self, ex: &Expr) -> t

fn ty_ctxt<'a>(&'a self) -> &'a ctxt

impl<'a> AstConv for FnCtxt<'a>

fn tcx<'a>(&'a self) -> &'a ctxt

fn get_item_ty(&self, id: DefId) -> Polytype

fn get_trait_def(&self, id: DefId) -> Rc<TraitDef>

fn ty_infer(&self, _span: Span) -> t

Derived Implementations

impl<'a> Clone for FnCtxt<'a>

fn clone(&self) -> FnCtxt<'a>

fn clone_from(&mut self, source: &Self)