10 ms·
Rust 1.0: Status report and final timeline
- breckinloggins 12y agoOne thing I'm less clear on is what will happen after 1.0. Is there a "post 1.0 wishlist" somewhere?
- steveklabnik 12y agoFunny you should ask: https://github.com/rust-lang/rfcs/labels/A-wishlist https://github.com/rust-lang/rfcs/labels/A-wishlist We have not done any scheduling for what comes after 1.0. I've been doing a huge amount of triage to move over issues that used to be in rust-lang/rust to be under that label, too, and to make it more detailed than just 'wishlist.' We'll figure out exactly what's next shortly before the first post-1.0 cycle actually begins. http://users.rust-lang.org/t/most-coveted-rust-features/324 http://users.rust-lang.org/t/most-coveted-rust-features/324 was a thread created recently, asking people what they want the most. You might find that interesting too.
- breckinloggins 12y agoThank you!
- kzrdude 12y agoA feature that has already seen many proposed rfcs and long discussions is "Efficient code reuse" (a.k.a some kind of inheritance), summarized here: https://github.com/rust-lang/rfcs/issues/349 https://github.com/rust-lang/rfcs/issues/349 It was explicitly postponed until after 1.0.
- wrl 12y agoThis is the big one I'm waiting on before betting the farm on Rust, and I suspect I'm not the only one.
- breckinloggins 12y agoI just wrote a comment on that issue with some half-baked ideas, but I really think that this is one of those "line in the sand" features that will determine (at least for me) whether rust is really staying true to its emerging identity or whether it's on the road to becoming another opinionated kitchen sink language. The thing about "efficient code reuse" is it probably requires dynamic dispatch. Once you have dynamic dispatch, you suddenly have vtables. But who decides what those vtables look like? Where do they reside in memory? What's the layout of that? If a struct suddenly has an is-a pointer, where is that mentioned in the code? Now my struct isn't just a struct. I love the rust idea that tons of modern language design still allows for zero-cost abstraction. Inheritance in dispatch starts getting into the land of "putting a lot more stuff in my binary than I asked you to", and I would argue that it's this property more than anything else that keeps embedded programmers and kernel guys safely in the minimalistic land of C. It would be nice to have a new C, finally. But the more a language has an opinion on runtime layout, behavior, and symbol names, the less C-like it becomes. Rust got this right when it decided that GC was NOT the correct default behavior for a language. The reason you see people playing with OS kernels in rust and not as much in D is, I think, mainly due to this decision. I think rust should continue carrying this torch. If not for the ability to have the best of both worlds (a modern language and access to to-the-metal programming with a controllable runtime layout and deterministic performance profile), where exactly is the value in learning how to use the borrow checker?
- steveklabnik 12y agoRust already supports dynamic dispatch[1], and the 'code re-use' proposals may not look like traditional inheritance. [2] Furthermore, they're being driven _by_ those low-level requirements: it's about being able to efficiently represent things that truly need it, like the DOM. 1: http://doc.rust-lang.org/book/static-and-dynamic-dispatch.html http://doc.rust-lang.org/book/static-and-dynamic-dispatch.ht... 2: http://www.reddit.com/r/rust/comments/2j78oh/i_heard_that_rust_will_get_inheritance_soon_but/cl9261m http://www.reddit.com/r/rust/comments/2j78oh/i_heard_that_ru...
- breckinloggins 12y ago
- mbrubeck 12y agoThis is not an official list, but it's one developer's opinion on post-1.0 priorities: http://featherweightmusings.blogspot.com/2014/12/my-thoughts-on-rust-in-2015.html http://featherweightmusings.blogspot.com/2014/12/my-thoughts... It also links to the list of RFCs that have been postponed until post-1.0: https://github.com/rust-lang/rfcs/issues?q=is%3Aopen+is%3Aissue+label%3Apostponed https://github.com/rust-lang/rfcs/issues?q=is%3Aopen+is%3Ais...
- larsberg 12y agoSince last July or so, Servo has been tracking all of the major features we'd like to see that have been postponed to post-1.0: https://github.com/servo/servo/issues/2854 https://github.com/servo/servo/issues/2854
- gtaylor 12y agoI haven't been tinkering with Rust, merely keep an eye on it until 1.0 lands. For those who are currently more in touch with the situation, does this release date look realistic, without quality suffering? Is the 1.0 release premature, aggressive, or very realistic? It seems like the standard library has seen a ton of work in the last month or two. I'm surprised at how aggressive the release schedule is, given how things are still churning a good deal.
- aturon 12y agoThere has been a lot of work on `std`, but it's largely been consistency, cleanup and cutting APIs down -- though the recent path and IO reforms are more substantial, which is why we decided to put out another alpha before finalizing them.
- kibwen 12y ago> For those who are currently more in touch with the situation, does this > release date look realistic, without quality suffering? Is the 1.0 > release premature, aggressive, or very realistic? I think it's aggressive, but I don't think it's unrealistic. Personally I had hoped for a late June/early July release to give more time to solidify the docs and to shake out bugs in the compiler. There will definitely be people who say that the release is premature, but I'm personally not one of them. The core of the language is ready, even if some pieces around the edges could still use some refinement (and will see refinement, backwards-compatibly, in the coming releases). > I'm surprised at how aggressive the release schedule is, > given how things are still churning a good deal. You'd be surprised at how much of a motivator a concrete release date is. :) Churn is happening now because of the impending release, not despite it. The language intends to have a solid compatibility story (via semver) for post-1.0 releases, so everyone who'd been holding off on changes for the past few years has suddenly come out of the woodwork to implement them.
- gtaylor 12y agoThat's re-assuring to hear. Thanks!
- netcraft 12y agoFrom the outside looking in, I am mostly impressed with the governance structure of the whole endeavor. It seems to me that it is a great model for other open source projects. Edit: as someone involved with other, less mature (and less ambitious) open source projects, if you know of pain points in the governance of rust, i'd be interested in learning about them.
- warnhardcode 12y agoI have only the vague understanding that there are governance structures in place for open source projects. Can you go into a little detail about what aspects of this project's governance impress you?
- netcraft 12y agoaturon's response below (https://news.ycombinator.com/item?id=9046882 https://news.ycombinator.com/item?id=9046882) outlines most of what I would say - really its the RFC process that I'm most interested with and how that is managed in an open way. There are always pet ideas and desires that complicate processes like this - the volume of RFC's the project has dealt with is impressive with no major community rifts that I have heard of. This page talks about the process and their code of conduct: https://github.com/rust-lang/rust/wiki/Note-development-policy https://github.com/rust-lang/rust/wiki/Note-development-poli...
- steveklabnik 12y agoOh, since you quoted that page, you might want to know about this PR: https://github.com/rust-lang/rust/pull/22282 https://github.com/rust-lang/rust/pull/22282
- codys 12y agoThere's a governance structure? That's news to me. I was under the impression that a few primary contributors (mostly/all mozilla employees?) are gatekeepers to merging anything. Having an "RFC" issue tracker isn't the same as having a governance structure. Edit: I suppose you could call the above a 'governance structure', but I'm having a hard time seeing anything impressive/different about it from other open source projects
- jarrettc 12y agoEven though 1.0 isn't out yet, today you can use Rust for many real projects. I'm unsure whether I'd bet my business on it yet, but I'd be open to the idea. And I'm usually a very late adopter. I've been building a 3d game with Rust and OpenGL, ported from a C++ codebase. So far, my experience has been very positive. Despite Rust's supposed immaturity, it feels more polished than C++ in many ways. Forward progress has been much faster than it was with C++. Does anyone else have a story (positive or negative) about using Rust in real projects?
- snake_case 12y agoSince you ported from a C++ codebase, how have you handled situations in your game where a lot of inhetitance was used? You may not even use inheritance much in the first place however, just curious about your rust-like solutions for typical c++ game development practices.
- kibwen 12y agoHere's a company using Rust to sandbox executable financial contracts: https://codius.org/blog/codius-rust/ https://codius.org/blog/codius-rust/ . The blog post is unfortunately light on details, but I'm hoping to hear more from them soon. I'd also love to see wycats or carllerche weigh in on Skylight.io's use of Rust from within a Rubygem.
- sitkack 12y agoMuch of the codius code is on github https://github.com/codius https://github.com/codius
- MichaelGG 12y agoI'm betting my business on it. I've written a network search engine in F# and it's in use on the VoIP arm of one of the public telcos. VoIP can generate terabytes of signalling data a day, even while not making much money. (In wholesale, many calls simply don't complete, so you've got a huge amount of data and transactions that pay you $0.) The challenge with F# is controlling memory usage. Even one extra allocation per packet can make a measureable difference in performance. I ended up doing a ton of unsafe code and manually managing most of the heap. Rust allows me to write fairly high-level code (not as expressive as F# yet but whatever) while getting "best" performance. Inline asm is a bonus, as there's some algorithms for integer compression that can use SIMD for big wins (I can do that in .NET, but it's ugly, and doing it safely means a ~30 instruction thunk). And sometimes in tight loops, I've found it difficult to get .NET to do acceptable codegen, causing double-digit% impacts. There's also the safety issues writing unsafe code for network-exposed traffic. So Rust is actually more safe than .NET, because I have to toss .NET's safety to gain performance. The backend management code I can continue to write in F#, and Rust's C-compatibility means it's trivial to interop the code. So I can do "orchestration" of indexing daemons and management APIs and such things in a higher-level language, then for actual indexing and whatnot, just jump over to Rust, seamlessly. Finally the static compilation means a smoother installation experience for customers. And if I ever ship a closed-source module that executes on the client, I don't need to license Mono for static linking. So that's nice. And the safety guarantees are good, because similar, existing, software in C has put customers at risk before. (I'm not sure if I can effectively market that last part, but hey.) Rust would appear to have a unique value proposition and I'm very pleased to see it progressing so damn well.
- drobilla 12y agoI'm very happy to see Rust stabilize, about time we get a systems(ish) programming language with a half decent type system. With that said... I need to get some bikeshedding off my chest: I hate to let such a triviality lower my enthusiasm for a language so much, but I just can not get over that awful inconsistent closure syntax :/ I don't get it. Most everything else has a nice unique keyword syntax, fn uses (args, in, parenthesis), proc syntax made consistent sense, then lambda is this crazy || linenoise thing that doesn't fit in at all. The "borrow the good ideas from other languages" approach has resulted in a great language, but "cram random syntax from other languages that doesn't fit" doesn't work out so well.
- steveklabnik 12y agoAs a Rubyist, I found the closure syntax quite comfortable, as they're almost identical. Passing a closure or lambda to some function foo: x = foo {|x| x + 1 } # Ruby let x = foo(|x| { x + 1 }); //Rust let x = foo(|x| x + 1 ); // single expressions don't need {}s That said, I'm not sure what the exact reason was for choosing the syntax, as that was before my time.
- aturon 12y ago> That said, I'm not sure what the exact reason was for choosing the syntax, as that was before my time. I think the reason is just that it's very concise, and lightweight closure syntax makes things like `Option::map` feel like first-class parts of the language. The closure you pass just sort of seamlessly "blends in". Note that having especially sugary here is not so uncommon, for example Haskell has `\x -> blah` for Rust's `|x| blah`. I'm personally very happy that the closure syntax is as concise as it is.
- pcwalton 12y agoThe natural thing to want in a C-like syntax is the "arrow function" closure syntax (like ES6 or C#), but that required too much lookahead to parse. Having a keyword discourages functional style, which would be a shame in a language with a powerful iterator library. So Rust went with the Ruby/Smalltalk-style bars, which are nice, concise, and easy to parse.
- andrewflnr 12y agoIt's good to hear that IO reform has finally landed. I expected to see an announcement in /r/rust. Did I just miss it? brb, updating my code...
- AlyssaRowan 12y agoRust looks interesting. One thing I'm not clear on it if can do, and that I'm interested in, is secure destructors. Say I'm handling crypto, and I'm carting around an ephemeral key. When this goes out of scope, I definitely no matter what, want this zeroised by its destructor - as opposed to just having it (or a temporary copy made by a compiler optimisation!) zombling around the heap, stack or forgotten unused xmm registers because the compiler figured since I don't reference it again, the memory's contents are no longer important. Current approaches to this involve explicit_bzero(), or other similar memset(0)-and-I-really-mean-it-don't-optimise-this-out techniques. (And a fair bit of testing and prayer when it comes to potential temporary copies or registers.) But unless you're doing it in assembly language, you don't really know. (The stack beneath you, such as the OS, any hypervisors, SMM, AMT, SGX, µcode etc, aside, of course!) I'm not quite clear what Rust's behaviour with this scenario is. If it can do this easily, even potentially, I am very interested…?
- heinrich5991 12y agoYou need to put the key material into an opaque struct, which does store it on the heap. Using the `black_box` function you can zero the key material out in the destructor.
- AlyssaRowan 12y agoI see. Which would be kind of similar to how you do it in C; the destructor is actually guaranteed to run when it goes out-of-scope? But what I'm a bit more worried about is how the secret data gets in there, and what happens while I'm working with it: expansion, cipher state, key setup, all the little adds and xors and rots (dammit, why doesn't ROT ever get some real operator love? It's got first-class instructions… :() - all that stuff you'd do in u32 and u64. Temporary copies may still be a problem, if you look at the object that actually comes out of compilers sometimes. Does using an opaque type actually deal with that issue here?
- MichaelGG 12y agoI know nothing about writing crypto core code. But... Rust supports inline assembly, so after you're done, you could always zeroize every register, right?
- q2 12y agoIs it possible to estimate the amount of manpower and time required to develop a new language from scratch till it is stable and reasonably production ready? Adoption of language is different topic, since it depends on users. Rust and Go are two reasonably new languages. I understand scope and priorities of each language may be different but my idea is to get some approximation/thumb rule for any one before starting similar journey. As per Github and wikipedia: Number of contributors for Rust and time taken so far: 840, and 2 years. Number of contributors for Go language and time taken so far: 424 and 6 years. Financial details are not known. It seems developing new language and bringing it to reasonable level is not trivial effort. 1. Is above data correct i.e. are those contributors full time working on those languages i.e. is it full time job of those people? 2. Can we get details like number of developers/number of test engineers/number of documentation writers ...etc? 3. Is it possible to know the total amount of financial resources consumed so far in the effort? 4. Is there any research into resources required for new language development in terms of man power, time, financial resources for various languages? It is fascinating to see a new language developed in front of us.
- steveklabnik 12y agoTo give you an idea, Rust is actually about 8 years old in total, though it was just Graydon for the first four and a half. The language recognizable as today's Rust is about two years old, though. But it still needed that gestation to get to that state, so I'd count all of them.
- Artemis2 12y agoBoth Google and Mozilla have teams dedicated to their languages, but they represent a very small portion of the total number of contributors to the language. I couldn't find exact lists of the team members inside both organizations. In terms of volume of contributions, for Go, Google employees are by far the most active: https://github.com/golang/go/pulse https://github.com/golang/go/pulse. In this graph, the 7 top contributors to the project are Google employees. The Rust pulse graph shows the same trend (https://github.com/rust-lang/rust/pulse https://github.com/rust-lang/rust/pulse), with the top 6 contributors being Mozillians (according to a few Google searches). Something that noteworthy about Go is the "quality" of the team members: Google has Ken Thompson, Rob Pike and Russ Cox working full time on the language. Mozilla may have a few great developers on Rust too, but Google is very serious about Go. I don't have any information about how financial and human resources are used by Google and Mozilla for the development.
- nathell 12y ago
- haberman 12y agoI saw that integer overflow has been revised: it now defaults to checking overflow in unoptimized builds. I got a little nervous about this when reading the performance-related objections of @thestinger here: https://github.com/rust-lang/rfcs/pull/560 https://github.com/rust-lang/rfcs/pull/560 At least optimized builds aren't affected, but it sounds like lots of code (including Rust nightlies) aren't built optimized.
- kibwen 12y agoThe nightlies are built with optimizations. And trust me, nobody's going to be distributing Rust binaries that weren't built with optimizations because Rust code built without optimizations has performance on par with Ruby rather than C++ (LLVM's optimization passes do a hell of a good job).
- haberman 12y agoAh sorry, my mistake. I think I had optimized builds confused with "ndebug" builds. But it sounds like only ndebug builds disable overflow checks, and Rust nightlies don't use ndebug.
- baq 12y agothestinger seems to have a kernel hacker or embedded systems attitude, which is probably lower than 1% of all use cases; that's not to say it's not important, but he's generated an unproportional amount of, let's say, loud signal.
- nikomatsakis 12y agoThe final draft made an effort to address those concerns -- but also they are completely inapplicable to optimized builds, as kibwen points out. (And if you care how fast your code runs, you really do want optimizations...)
- haberman 12y agoAFAICS these concerns apply even to optimized builds unless they are also "ndebug", right?
- dkhenry 12y agoI am going to be happy when I can program in rust and not spend the first hour making all my code work with the latest compiler changes. I really do like what rust is offering, but tracking head has been difficult
- breckinloggins 12y agoMe too! I have yet another NES-emulator-in-rust project [1] and I've been hesitating on picking it back up because I only want to convert to "new rust" once. It looks like April will be a good month. [1] https://github.com/breckinloggins/rusticom https://github.com/breckinloggins/rusticom
- TwoBit 12y agoSome language guy told me that Rust's ownership system is untenable. He said that researchers tried the same thing years ago and it was concluded to be impossible to work well. I know that's vague, but he claimed to know what he was talking about.
- conradk 12y agoMost of the time, Rust's ownership system is helpful. Sometimes, it's a pain though. In these cases, you can actually work around the ownership system if you need too. For instance, you can use Arc [1] to share memory between threads or Rc [2] to enable thread local GC for a specific variable or RefCell [3] to safely share mutable memory between threads. You can even use raw pointers: it's unsafe (and therefore has to be wrapped in an "unsafe { ... }" block) but possible. Finally, you can call C very easily from Rust [4]. [1] http://doc.rust-lang.org/std/sync/struct.Arc.html http://doc.rust-lang.org/std/sync/struct.Arc.html [2] http://doc.rust-lang.org/std/rc/struct.Rc.html http://doc.rust-lang.org/std/rc/struct.Rc.html [3] http://doc.rust-lang.org/std/cell/struct.RefCell.html http://doc.rust-lang.org/std/cell/struct.RefCell.html [4] http://doc.rust-lang.org/book/ffi.html http://doc.rust-lang.org/book/ffi.html
- steveklabnik 12y agoYou should ask him to get in touch. If something's broken, we want to know about it.
- pcwalton 12y agoRust goes a lot farther than academic languages that used regions like Cyclone or the ML Kit. In particular, Rust's regions are only used to enforce stack discipline, and the basic memory management is taken from C++. This way, we avoid the well-known limitations of "classical" region-based memory management. Besides, consider the fact that we've written hundreds of thousands of code for working, non-toy projects in the language, including the Rust compiler, crates.io, Servo, etc.
- jroesch 12y agoResearchers will often say things like this about techniques they couldn't get working as a way to explain away their failures. Often times some one will come along a couple years later and do exactly what they claimed was impossible or untenable. I've heard people claim that improvements on their techniques are impossible, and that proposed improvements "won't work" when it in fact does (source: I've seen this happen in the research community more than once).
- cw0 12y agoIs it safe to assume that anyone wishing to learn Rust can, by alpha2, study The Rust Programming Language and Rust By Example and not need to relearn anything within that scope after 1.0 lands?
- jroesch 12y agoThe core language is almost completely fixed, and the only real changes will be in unstable areas like associated types. There might be some small API changes but all APIs are marked with stability levels so you should be able to figure out what is stable, and what is not.
- jroesch 12y agoThe core language is almost completely fixed, and the only real changes will be in unstable areas like associated types. There might be some small API changes but all APIs are marked with stability levels so you should be able to figure out what is stable, and what is not.
- moonchrome 12y agoI'm excited by what Rust will eventually bring to the table if it ever gets popular - a higher level C++ (tools for writing safe native code) replacement without the legacy crap (header files...) At the same time I don't think I would use Rust 1.0 in production for two reasons : * the language doesn't seem to be mature enough to be highly productive, for eg. the type system isn't powerful enough to express stuff like Iterable or VectorTN and I'm sure there is plenty of tedious stuff like that along with pains from ownershinp systems * tools and libs are obviously not there So I guess I'll wait for early adopters to write the libs and give feedback on their painpoints to the devs. I've said this before - I think Rust 1.0 is something that I could use (ie. working and stable) but I don't think it's something that I'd want to use yet.
- qznc 12y agoAnybody wants to bet some play-money on the release date? http://www.knewthenews.com/Market/44777/Will%20Rust%201.0%20be%20released%20before%20May%2016%3F http://www.knewthenews.com/Market/44777/Will%20Rust%201.0%20...