rust-lang/rust
View on GitHub ↗ ★ 120,971 Rust
Empowering everyone to build reliable and efficient software.
1,825 mentions on Hacker News by 819 people: 158 stories, 1,667 comments · first 2012-01-20 · latest 2026-10-22
20082026
-
> Edit: if you downvote, reply with a link to the last compiler you wrote. https://github.com/rust-lang/rust/
comment by pcwalton · 2022-12-01 · in Memory Safe Languages in Android 13 -
…`allow_internal_unsafe` which allows you to use unsafe code inside a macro. But after this PR( https://github.com/rust-lang/rust/pull/57467 ) was merged, you can no longer use this attribute when unsafe code is forbidden. So how can you…
comment by kxxt · 2022-11-27 · in Safe Rust Code That Segfaults -
…of Vec have an example, which is doctested, and yet Vec still has an extensive suite of unit tests: https://github.com/rust-lang/rust/blob/master/library/alloc/... Technically you could use doctests as a literate-ish test framework…
comment by masklinn · 2022-11-27 · in Doctests in R -
…{ fn foo(&self, t: T); } > Multiple if let cases They are a work in progress, available in nightly: https://github.com/rust-lang/rust/issues/53667 But they do require an extra level of parens in some cases, though I think that's…
comment by pitaj · 2022-11-26 · in Choosing Nim out of a crowded market for systems programming languages -
It is a little more complex than that these days https://github.com/rust-lang/rust/blob/4e0d0d757e2f1b61ec809...
comment by steveklabnik · 2022-11-23 · in Using Rust at a startup: A cautionary tale -
Bringing that feature to Rust was under discussion for a while but it was ultimately withdrawn: https://github.com/rust-lang/rust/issues/27779#issuecomment-...
comment by conradev · 2022-11-17 · in Is Rust stack-efficient yet? -
…it's a completely normal part of writing Rust (and LLVM optimizations have finally been turned on: https://github.com/rust-lang/rust/issues/54878 ) Also see https://github.com/rust-lang/rust/pull/103070 and https://reviews.llvm.org/D136659…
comment by howinteresting · 2022-11-14 · in Tell HN: Rust Is Complex -
…crate. This causes spurious warnings to be emitted if you want to share code between tests. See https://github.com/rust-lang/rust/issues/46379 Modules and crates continues to be one of the most confusing aspects of Rust, for me at least.
comment by ridiculous_fish · 2022-11-13 · in Carefully exploring Rust as a Python developer -
…improved to the point that they're now competitive or faster than parking_lot, at least on Linux: https://github.com/rust-lang/rust/pull/95035#issuecomment-10... Channels appear to be trickier, but it might be possible to upstream…
comment by kibwen · 2022-11-07 · in Blessed.rs – An unofficial guide to the Rust ecosystem -
Adding allocator support does add a bit more noise: https://github.com/rust-lang/rust/pull/103093/files#diff-8bd...
comment by mastax · 2022-11-05 · in In defense of linked lists -
…considered. AFAICT this work is being done in the broader context of async methods, tracked here: https://github.com/rust-lang/rust/issues/91611
comment by kibwen · 2022-11-03 · in Rust 1.65.0 -
…the GAT stabilization PR that compiles a list of crates that use GATs or would like to use them: https://github.com/rust-lang/rust/pull/96709#issuecomment-11... Here's a collection of comments from the same PR from users arguing for…
comment by kibwen · 2022-11-03 · in Rust 1.65.0 -
Originally OCaml, and now Rust: https://github.com/rust-lang/rust
comment by nequo · 2022-10-25 · in Stranger Strings: An exploitable flaw in SQLite -
…optimization, providing 10-20% improvements to compiler performance", per Rust's release notes: https://github.com/rust-lang/rust/blob/master/RELEASES.md ).
comment by itamarst · 2022-10-23 · in How Rust 1.64 became faster on Windows -
Tldr: PGO https://github.com/rust-lang/rust/pull/96978/
comment by mastax · 2022-10-23 · in How Rust 1.64 became faster on Windows -
…symbols to the FFI module[0], but untangling `usize` might not be possible at this point. [0] https://github.com/rust-lang/rust/issues/88345
comment by jmillikin · 2022-09-23 · in The road to Zettalinux -
…they are working on getting support for it in external tools and writing up the documentation. https://github.com/rust-lang/rust/issues/60705 https://github.com/rust-lang/rfcs/pull/2603
comment by pabs3 · 2022-09-23 · in Traditional packaging is not suitable for modern applications? -
…use it. https://wiki.debian.org/StaticLinking#Rust https://github.com/rust-lang/rfcs/pull/2603 https://github.com/rust-lang/rust/issues/60705
comment by pabs3 · 2022-09-23 · in Traditional packaging is not suitable for modern applications? -
…and most of the API is just simple convenience combinators with obvious implementations: https://github.com/rust-lang/rust/blob/master/library/core/s... If nothing else, this is a clear counterexample to the claim that "Option and Result…
comment by Rusky · 2022-09-22 · in C++ by Example -
Yes, and the pointer management is all done using unsafe blocks: https://github.com/rust-lang/rust/blob/master/library/alloc/...
comment by ajross · 2022-09-20 · in It's time to halt starting any new projects in C/C++ -
> Even a doubly-linked list is impossible to get through the borrow checker. https://github.com/rust-lang/rust/blob/master/library/alloc/... It's part of standard lib. And you don't get more idiomatic than that.
comment by Ygg2 · 2022-09-20 · in It's time to halt starting any new projects in C/C++ -
…ts.llvm.org/pipermail/llvm-dev/2018-November/1276... Which causes a good bit of awkwardness for Rust: https://github.com/rust-lang/rust/issues/73328 The solution is to not attempt to store payload-laden NaN as any kind of floating point…
comment by MaulingMonkey · 2022-09-20 · in NaN Boxing (2020) -
…RFC and how their sole purpose is to not have to add HKTs. From the collapsed discussion in the OP. https://github.com/rust-lang/rust/pull/96709#issuecomment-11...
comment by Gwypaas · 2022-09-13 · in Rust stabilizes generic associated types -
…and simpler library code (which is usually an improvement in reliability and maintainability). https://github.com/rust-lang/rust/pull/96709#issuecomment-11... Has an extensive list of libraries wanting to use GATs, with their…
comment by masklinn · 2022-09-13 · in Rust stabilizes generic associated types -
…traits You're probably already aware, but for the bystanders, that seems to be close to happening: https://github.com/rust-lang/rust/issues/63063 > - Mutability variance: e.g. write `fn index<&a>(&a self, idx: Idx) -> &a T`, instead of…
comment by proto_lambda · 2022-09-13 · in A personal list of Rust grievances -
…Both of such conclusions aren't true in practice. [0]: https://crates.io/crates/fake-static [1]: https://github.com/rust-lang/rust/issues/25860
comment by kprotty · 2022-09-12 · in Zig VP of community comments on Rust -
…one of my first additions to the standard library also ran into this, but at a way smaller scale: https://github.com/rust-lang/rust/issues/41793 Back then we didn't have the PR yet that would make nightly functions not conflict with…
comment by est31 · 2022-09-11 · in Abstracting over ownership in Rust with higher-rank type bounds? -
…break the no-less-than 319 crates that directly or transitively depend on `Itertools::intersperse`: https://github.com/rust-lang/rust/pull/89638 Speaking as one of the maintainers of itertools: This whole situation feels kinda awful, and…
comment by jswrenn · 2022-09-11 · in Abstracting over ownership in Rust with higher-rank type bounds? -
https://github.com/rust-lang/rust/issues/88967 : they've delayed adding an `Iterator::intersperse()` method to the standard library, since it conflicts with the `Itertools::intersperse()` method from the popular `itertools` crate.
comment by LegionMammal978 · 2022-09-11 · in Abstracting over ownership in Rust with higher-rank type bounds? -
…in the right direction. I'm really grateful to all the people who work on it. [1] I just ran into https://github.com/rust-lang/rust/issues/55795 , for example.
comment by agalunar · 2022-09-11 · in Zig VP of community comments on Rust -
…implementation work has been done, and a stabilization report was even put forward back in July: https://github.com/rust-lang/rust/issues/54503#issuecomment-...
comment by eddyb · 2022-09-07 · in Zig, the Small Language -
…link are used specifically to ensure correct handling of Rust multi-level breaks work syntax, like https://github.com/rust-lang/rust-analyzer/blob/master/crate... , https://github.com/rust-lang/rustfmt/blob/master/tests/sourc... ,…
comment by eesmith · 2022-09-04 · in Python multi-level break and continue -
Forgot that HN strips the line number. Actual link: https://github.com/rust-lang/rust/blob/d0ea1d767925d53b2230e...
comment by Grimburger · 2022-09-04 · in Problematic Constants in Rust -
Rust has a standard library working as something akin to a runtime, period. https://github.com/rust-lang/rust/blob/33916307780495fe311fe...
comment by anthk · 2022-09-03 · in Tor – Arti 1.0.0 is released: Rust Tor implementation ready for production use -
Related, Rust's main(): https://github.com/rust-lang/rust/blob/1.62.0/library/std/sr...
comment by olalonde · 2022-08-23 · in A general overview of what happens before main() (2019) -
Only a partial set, though: https://github.com/rust-lang/rust/blob/master/compiler/rustc...
comment by jeroenhd · 2022-08-20 · in Unicode Utilities: Confusables -
…target will (very likely) be available in Rust 1.64.0 [0]. [0]: https://github.com/rust-lang/rust/pull/88991#issuecomment-11...
comment by anonova · 2022-08-19 · in Unofficial Spotify Client for the Nintendo Switch (PoC) -
…they made some of the core traits in the serializer infallible (ie. panic instead of using Result): https://github.com/rust-lang/rust/pull/93066 Writeup from the contributor: https://nnethercote.github.io/2022/02/25/how-to-speed-up-the...…
comment by ninkendo · 2022-08-08 · in Using unwrap() in Rust is okay -
The primary Rust implementation, https://github.com/rust-lang/rust , is written in Rust.
comment by thesuperbigfrog · 2022-08-08 · in Rust Code for the Linux Kernel Updated with More Features Implemented -
…also touches on stable ABI). `rustc` just calls into the .so without any custom configuration: https://github.com/rust-lang/rust/blob/e141246cbbce2a6001f31... (but rustdoc/clippy/miri all have additional configuration, passes, etc.…
comment by eddyb · 2022-08-03 · in The end of Optane is bad news -
…¹ via forcing the dynamic linker to eagerly resolve some symbols, global constructors, etc. - see https://github.com/rust-lang/rust/issues/73917#issuecomment-... for some recent discussion ² such as exporting a single base symbol per dylib…
comment by eddyb · 2022-08-03 · in The end of Optane is bad news -
For reference, the tickets GP is talking about are - https://github.com/rust-lang/rfcs/pull/3127 - https://github.com/rust-lang/rust/issues/40552
comment by estebank · 2022-07-26 · in RustDesk – Open-source TeamViewer alternative -
…are more subtle things like qualified paths such as this testcase which could be argued is valid https://github.com/rust-lang/rust/blob/master/src/test/ui/qu... but there was some discussion on zulip which clarifies it:…
comment by philberty · 2022-07-26 · in Ferrocene: Rust toolchain to safety-critical environments -
Alongside with Windows long since 1.35 https://github.com/rust-lang/rust/pull/20367
comment by znwu · 2022-07-24 · in The Rust Performance Book (2020) -
I believe this tracks it: https://github.com/rust-lang/rust/issues/32838
comment by kaba0 · 2022-07-22 · in Some Thoughts on Zig