Originally posted by schmidtbag
View Post
Announcement
Collapse
No announcement yet.
Making The Case For Using Rust At Low Levels On Linux Systems
Collapse
X
-
-
Originally posted by cl333r View PostBut even for user-space. I'm doing Qt5 and the Rust binding I found [1] has only one example and this TODO list:- More Qt modules support
- Global Qt functions support
- Qt enums support
- Qt generic container classes support
- Operator methods support
In other words it's not worth for me switching from a known language (C++11) with a good and known building system (cmake) with a good toolkit (qt5) to: an unknown but allegedly superior language (Rust) with an unknown building system (cargo or whatever) with inferior bindings to Qt5.
I'm trying to be unbiased here since I'm interested in good stuff, but Rust's pros and cons just don't do it for now for me.
[1] https://github.com/kitech/qt.rs
- Likes 1
Comment
-
Originally posted by liam View Post
Rust only claims performance parity with c++ iff c++ is written with similar safety guarantees as idiomatic rust. That's not a real issue, imho. Rust is fast enough for many (maybe most) userspace applications. It's libraries, however, may not be as mature as we'd expect from something like libc.
Comment
-
Originally posted by zanny View Post
There are plenty of use cases for Qt as a systems library framework. It is really useful just for its json / http daemon / dbus support in many cases, albeit you can get the same from boost with much less dependency bloat.
- Likes 1
Comment
-
Originally posted by totoz View PostI wonder why suddenly Rust generates so much hype while Ada has been there for years.- Ambition:
- Rust aims to be a systems programming language that takes advantage of the best of the best ideas that have come before in functional and imperative languages, and further expand upon them.
- Not only does it aim to be as fast as C for low level systems programming, even for embedded development, but it aims to be the best high level systems programming language without the cost of high level programming.
- The development of the Rust standard library and compiler is so that Rust will always be a moving target that will keep up with technological advancements as they come.
- They hired full-time staff to design a beautiful website and theme for all of their web content, including the automatic code generator. Ada's website, in comparison, looks like a cheap HTML template designed to appeal towards business suits rather than programmers.
- They have also hired full-time staff to focus on improving the quality of Rust documentation, and regularly report on progress via This Week in Rust Docs.
- Community:
- The stronger the ecosystem of libraries, the stronger a language becomes, but a language can never gain libraries without an active community.
- Node was able to explode in popularity thanks to the Node Package Manager, and it has been one of the most successful attempts of open source software to take over the desktop, despite being based on web technologies. Rust provides it's own NPM-like solution with Cargo.
- The Rust community is focusing a lot on promoting an actual community through active forums, blogs, IRC channels, a subreddit, and even social media.
- The Code of Conduct ensures civility in the community rather than hostility that is common in other communities.
- Organization:
- Mozilla is really good at organizing community resources. Just check out how much detail and effort that has been placed into every section of their website, including how they are managing their GitHub repository.
You really have to ask yourself. How many languages have come about that are as ambitious, community-oriented, and managed as well as Rust?
- Likes 4
Comment
- Ambition:
-
Originally posted by mmstick View Post
Rust doesn't prevent one from using the unsafe keyword to disable bounds checking and achieve C performance or go beyond. It's still idiomatic Rust, even if you use unsafe functions like get_unchecked(). The only thing lacking for Rust in performance right now is for the simd crate to become stable and shipped with Rust by default.
Btw, I'm not attempting to downplay the achievement of rust.
Comment
-
Originally posted by mmstick View Post
Three critical things: ambition, community, and organization.- Ambition:
- Rust aims to be a systems programming language that takes advantage of the best of the best ideas that have come before in functional and imperative languages, and further expand upon them.
- Not only does it aim to be as fast as C for low level systems programming, even for embedded development, but it aims to be the best high level systems programming language without the cost of high level programming.
- The development of the Rust standard library and compiler is so that Rust will always be a moving target that will keep up with technological advancements as they come.
- They hired full-time staff to design a beautiful website and theme for all of their web content, including the automatic code generator. Ada's website, in comparison, looks like a cheap HTML template designed to appeal towards business suits rather than programmers.
- They have also hired full-time staff to focus on improving the quality of Rust documentation, and regularly report on progress via This Week in Rust Docs.
- Community:
- The stronger the ecosystem of libraries, the stronger a language becomes, but a language can never gain libraries without an active community.
- Node was able to explode in popularity thanks to the Node Package Manager, and it has been one of the most successful attempts of open source software to take over the desktop, despite being based on web technologies. Rust provides it's own NPM-like solution with Cargo.
- The Rust community is focusing a lot on promoting an actual community through active forums, blogs, IRC channels, a subreddit, and even social media.
- The Code of Conduct ensures civility in the community rather than hostility that is common in other communities.
- Organization:
- Mozilla is really good at organizing community resources. Just check out how much detail and effort that has been placed into every section of their website, including how they are managing their GitHub repository.
You really have to ask yourself. How many languages have come about that are as ambitious, community-oriented, and managed as well as Rust?
You mention the CoC (and if add its actual enforcement) but I think, in one case, at least, its attempt to fit everyone in a square slot (I realize civility shouldn't be viewed as such but it's an imperfect world) led to the loss of a really brilliant developer/contributor. For people like that, imho, you should provide an alternate* slot.
*obviously, even for them, there are limits, but rudeness should be tolerated to degree that the person contributes
Comment
- Ambition:
-
Btw. rust does only bound checking when neccessary. It doesn't do any bound checking in safe code when you are iterating over an array with for each.
And it has overflow detection in debug mode which gets disabled in realease mode. Unit tests are integrated in the standard lib and compiler.
If you are documenting code examples in your docs, these examples will get checked if they are compilable.
In total, rust gives you an amazing tool chain by default!
Comment
-
Originally posted by mmstick View PostWhy should anyone care about Qt support? Qt isn't supported by any language other than C++, and it's not the best graphical toolkit for Linux. Cross-platform UI toolkits tend to use GTK3 as the backend for Linux, and Rust has amazing support for GTK3.
Also, from my little experience in both GTK and Qt, the last is better to code. E.g. I remember, as part of a student thesis, I was trying to fix a problem in GTK GUI of Yi with cursor, which doesn't become «big black box» in «normal mode», like it is in vim. Long story short, it turned out GTK didn't have that capability. In GVIM it is done via custom widget, and someone told a story, that for alike needs they hacked the mode of cursor when you press «Insert» key.
I also met some other problems, which I badly remember, but what I do remember — I googled whether they could be easily done in Qt, and yes, they are! Plus — though it is subjective — to me Qt apps looks much prettier than GTK ones. So I consider Qt to be better than GTK.
The only thing I'm miss in Qt, is that GTK allows creating global keybindings for textboxes via .gtkrc, e.g. for movement like in Emacs.
- Likes 2
Comment
Comment