4 ms·
How did they stabilize this so fast? I feel like we first heard about this feature only a few months ago. Meanwhile I've been waiting for `let_chains` since wha
by thurn 5y ago
How did they stabilize this so fast? I feel like we first heard about this feature only a few months ago. Meanwhile I've been waiting for `let_chains` since what feels like the mid 90s...
- talideon 5y agoLots of useful prior art to work off of from Python and C#, I'd say.
- lmkg 5y agoThe link below is the pull request for the feature. The RFC dates to 2019, and the tracking issue is slightly more than two years old. I'm guessing we only started hearing about it when it became close to stabilization (around November last year?). https://github.com/rust-lang/rust/pull/90473/ https://github.com/rust-lang/rust/pull/90473/
- kibwen 5y agoThis feature has been in the works for quite a while. I suspect you're thinking of a different but possibly-related change, where the 2021 edition has reserved the syntax for new string literals forms (beyond the existing b and r forms). In theory those new forms could be used to permit f-strings. But the new capability mentioned in the OP is the ability to implicitly capture names in format strings, which works with the existing formatting macros (such as println). That said, Rust isn't a company, it's a volunteer organization, and features advance at the speed of enthusiasm. If there's a feature that someone wants to see, there's no use waiting around for it, someone's got to be the one to push it forward. :)