Struct rustc_borrowck::borrowck::Loan [−][src]
pub struct Loan<'tcx> { index: usize, loan_path: Rc<LoanPath<'tcx>>, kind: BorrowKind, restricted_paths: Vec<Rc<LoanPath<'tcx>>>, gen_scope: Scope, kill_scope: Scope, span: Span, cause: LoanCause, }
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Record of a loan that was issued.
Fields
index: usize
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
loan_path: Rc<LoanPath<'tcx>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
kind: BorrowKind
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
restricted_paths: Vec<Rc<LoanPath<'tcx>>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
gen_scope: Scope
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
gen_scope indicates where loan is introduced. Typically the
loan is introduced at the point of the borrow, but in some
cases, notably method arguments, the loan may be introduced
only later, once it comes into scope. See also
GatherLoanCtxt::compute_gen_scope
.
kill_scope: Scope
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
kill_scope indicates when the loan goes out of scope. This is
either when the lifetime expires or when the local variable
which roots the loan-path goes out of scope, whichever happens
faster. See also GatherLoanCtxt::compute_kill_scope
.
span: Span
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
cause: LoanCause
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Methods
impl<'tcx> Loan<'tcx>
[src]
impl<'tcx> Loan<'tcx>
pub fn loan_path(&self) -> Rc<LoanPath<'tcx>>
[src]
pub fn loan_path(&self) -> Rc<LoanPath<'tcx>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?