On recursive ADT, provide indirection structured suggestion#72740
On recursive ADT, provide indirection structured suggestion#72740bors merged 3 commits intorust-lang:masterfrom
Conversation
|
(rust_highfive has picked a reviewer for you, use r? to override) |
There was a problem hiding this comment.
This suggestion isn't entirely correct, but if used the compiler will correctly tell you to write
enum MList<'a> { Cons(isize, &'a MList), Nil }so I think it is ok.
There was a problem hiding this comment.
These suggestions are now fairly long. While I don't have a strong opinion here, it may be better to only mention Box and & here.
There was a problem hiding this comment.
Or thinking more about it, I would prefer if we keep
help: insert indirection (e.g., a
Box,Rc, or&) at some point to makeFoorepresentable
and only add an example using Box.
matthewjasper
left a comment
There was a problem hiding this comment.
I'm also a bit concerned by the length of this suggestion.
9bc1ea2 to
c209040
Compare
|
@bors r+ |
|
📌 Commit c209040 has been approved by |
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
|
Failed in https://github.com/rust-lang/rust/runs/744866295: Probably needs a re-bless. |
c209040 to
03552ec
Compare
|
@bors r=matthewjasper rebased |
|
📌 Commit 03552ec has been approved by |
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
…atthewjasper On recursive ADT, provide indirection structured suggestion
Rollup of 10 pull requests Successful merges: - rust-lang#72707 (Use min_specialization in the remaining rustc crates) - rust-lang#72740 (On recursive ADT, provide indirection structured suggestion) - rust-lang#72879 (Miri: avoid tracking current location three times) - rust-lang#72938 (Stabilize Option::zip) - rust-lang#73086 (Rename "cyclone" to "apple-a7" per changes in upstream LLVM) - rust-lang#73104 (Example about explicit mutex dropping) - rust-lang#73139 (Add methods to go from a nul-terminated Vec<u8> to a CString) - rust-lang#73296 (Remove vestigial CI job msvc-aux.) - rust-lang#73304 (Revert heterogeneous SocketAddr PartialEq impls) - rust-lang#73331 (extend network support for HermitCore) Failed merges: r? @ghost
No description provided.