3 ms·
I witnessed a similar case while touring D as an outsider. When Rust was new and the concept of lifetime was brought to the D community, it was deemed unnecessa
by xpressvideoz 3y ago
I witnessed a similar case while touring D as an outsider. When Rust was new and the concept of lifetime was brought to the D community, it was deemed unnecessary by Walter. A few years later, he brought his own lifetime proposal that is sufficiently different to Rust's and thus even less verified compared to the previous suggestion from the community. Now that I lost my interest in D, I'm not sure of the maturity of the new lifetime feature, but I would be surprised if it is as useful as Rust's.
- bsdpufferfish 3y agoSo now you can have a project with someone else's opinion instead of Walter's.
- xpressvideoz 3y agoNot someone else, but many others. I value projects governed by multiple people because one person cannot be an expert in every field, even though that person is smarter than most people.
- tonyedgecombe 3y agoThere are two sides to that. Once you start running a project by committee you will find all sorts of odd features winding their way through the system. Politicking has as much influence as technical merit when it comes to new proposals.
- fasterik 3y agoI'm not too familiar with either Rust's or D's approach to lifetimes, but from some quick forum searching, it appears that adding Rust-like lifetimes to D would have required significant changes to the design of the language. Every potential feature has tradeoffs in terms of how it interacts with other language features, adds cognitive overhead, decreases compilation speed, complicates the design of the standard library, breaks backward compatibility, etc. I don't think it's reasonable to expect a large-scale overhaul just to support one feature you like from another language.
- Conscat 3y agoGiven that Sean Baxter already has lifetimes in Circle that work very similarly to Rust's, I'm skeptical that the very similar D language wouldn't be able to express the same thing.
- tialaramex 3y agoGenerously, you've confused somebody saying they're interested in working on a problem with them having a working solution to the problem. Circle does not, in fact, have working Rust style lifetimes. Sean splits the Circle documentation into features which work and "Research" features Sean is working on and lots of interesting ideas, including lifetimes, are in the second category. Maybe Circle will implement them some day, or maybe it will not.
- steveklabnik 3y agoMy understanding is that he has been implementing them? I remember seeing screenshots like this go around back when I was on twitter: https://twitter.com/seanbax/status/1744403554155041047 https://twitter.com/seanbax/status/1744403554155041047 https://twitter.com/seanbax/status/1685671828767879168 https://twitter.com/seanbax/status/1685671828767879168
- Conscat 3y agoThey've been the primary focus of Circle for the better part of a year now. He's demo'd them working many times already.
- WalterBright 3y agoD's ownership/borrowing system does not require any language changes. It is opt-in at the function level to preserve compatibility with existing code. It does not break backward compatibility. It works as a prototype now, you can try it out. It does decrease compilation speed, because O/B requires data flow analysis. However, this is speed slowdown only happens for the functions marked as being O/B functions.