]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/closures/2229_closure_analysis/run_pass/capture-disjoint-field-tuple.rs
3 // Test that we can immutably borrow an element of a tuple from within a closure,
4 // while having a mutable borrow to another element of the same tuple outside the closure.
6 #![feature(capture_disjoint_fields)]
7 //~^ WARNING: the feature `capture_disjoint_fields` is incomplete
8 //~| NOTE: `#[warn(incomplete_features)]` on by default
9 //~| NOTE: see issue #53488 <https://github.com/rust-lang/rust/issues/53488>
10 #![feature(rustc_attrs)]
19 // `c` only captures t.0, therefore mutating t.1 is allowed.