Rust 1.65.0 released
Plain block expressions can now be labeled as a break target, terminating that block early. This may sound a little like a goto statement, but it's not an arbitrary jump, only from within a block to its end. This was already possible with loop blocks, and you may have seen people write loops that always execute only once, just to get a labeled break.
Posted Nov 3, 2022 18:06 UTC (Thu)
by roc (subscriber, #30627)
[Link]
However my favourite change in this release is actually "let ... else" ... I've written so much code that would be more readable with "let ... else"!
Posted Nov 3, 2022 18:17 UTC (Thu)
by mb (subscriber, #50428)
[Link] (4 responses)
Posted Nov 3, 2022 20:06 UTC (Thu)
by zaitseff (subscriber, #851)
[Link] (3 responses)
Posted Nov 3, 2022 20:16 UTC (Thu)
by tchernobog (guest, #73595)
[Link]
GATs are likely to be adopted quite fast, especially for things such as iterators, given that certain things were simply not possible to express satisfactorily before, or without a lot of workarounds. For an article listing some workarounds that were necessary before, see https://lukaskalbertodt.github.io/2018/08/03/solving-the-...
Things such as break from labeled blocks... well, they are kind of syntactic sugar anyway, so there's no big push there.
Posted Nov 3, 2022 22:08 UTC (Thu)
by atnot (guest, #124910)
[Link]
For example, one can look at the async ecosystem: When async was first added, the only support for it was the external futures crate. Only later, as confidence in the fitness of that implementation grew, did the relevant features land in the standard library.
Posted Nov 4, 2022 19:41 UTC (Fri)
by khim (subscriber, #9252)
[Link]
No. It's similar to Linux Kernel process: first some foundational code lands, then things which rely on it land. In particular this release doesn't expose any GAT-using APIs. After feature is enabled in the language third-party crates may test it. After it's tested in third-party crates it's brought to
Posted Nov 4, 2022 11:03 UTC (Fri)
by scientes (guest, #83068)
[Link] (4 responses)
Exact opposite of RISC-V which decided to completely divest from the US empire because of unnecessary political baggage involved.
Posted Nov 4, 2022 15:15 UTC (Fri)
by larkey (guest, #104463)
[Link]
Posted Nov 4, 2022 20:51 UTC (Fri)
by roc (subscriber, #30627)
[Link] (2 responses)
Posted Nov 5, 2022 16:28 UTC (Sat)
by scientes (guest, #83068)
[Link] (1 responses)
It also looks almost the same as Saudi Arabia hate, and they have DEFINITELY been showing how much they LOVE the US recently, and just want to bend over backwards and take Uncle Sam's penis whenever Uncle Sam seeks to destroy yet another country.
Posted Nov 5, 2022 16:35 UTC (Sat)
by corbet (editor, #1)
[Link]
Rust 1.65.0 released
Rust 1.65.0 released
These features will improve the readability of Rust code by a lot.
Pardon my ignorance of the Rust development process: when a new version of Rust is released with such new features (which do hopefully make code more readable), is the Rust Standard Library simultaneously updated to use these new features? Or is it a more gradual process that potentially might never happen?
Rust 1.65.0 released
Rust 1.65.0 released
Rust 1.65.0 released
> Pardon my ignorance of the Rust development process: when a new version of Rust is released with such new features (which do hopefully make code more readable), is the Rust Standard Library simultaneously updated to use these new features?
Rust 1.65.0 released
std. But some features stay in that mode for yearsRust 1.65.0 released
Rust 1.65.0 released
Rust 1.65.0 released
Rust 1.65.0 released
Regardless of one's opinion on the topic at hand or how you express yourself, this is far off-topic and inappropriate for LWN. This account is now moderated; everybody else please just let this end here.
Stop here
