Taylor Yu

Results 64 comments of Taylor Yu

There's a lot of helpful information here https://rust-lang.github.io/rfcs/2094-nll.html#reborrow-constraints but NLL are apparently not formally stabilized yet, even though their implementation has been in stable for years. Hopefully we can add...

This is one of the shortest examples I could write to illustrate the difference between a reborrow and a forbidden immutable borrow of a mutably borrowed value: ```rust #![allow(unused)] fn...

> Reborrow is actually covered as one specific kind of "coercion", and is already covered in the reference. It's indeed nice to expand and explain more clearly. I guess I...

> > but I think it's missing quite a few things, like how should I expect coercion to work with non-Copy types? > > The term `Copy` does not appear...

> A systems language like Rust should probably have all scenarios that cause implicit reborrows clearly defined. I think implicit *borrows* are fairly well defined. It might not be well-defined...

One place where Rust's magic might be adequately documented is method call coercions: the Reference has a fairly complete list of transformation of the receiver types, and any surprising behavior...

I'm not sure I've found all of the relevant references, but it seems like the `!` "never" type is still partially unstable, yet documented in the reference. Maybe we could...

> Yea, this is a known issue, see #869. It's a bit unfortunate that unstable syntax isn't feature gated in the parser. It is not clear to me how the...

I think this should have S-waiting-on-stabilization removed; the tracking ticket rust-lang/rust#44493 has closed (notably with the "Adjust documentation" step unchecked). (I'll try to get rustbot to do it, but I...

I'm willing to work on a PR for this. The "Reference-level explanation" in rust-lang/rfcs#2093 is quite verbose and possibly better suited for implementation documentation. I think I won't copy it...