News for hackers. Stuff that matters.
Re:The humble for loop in Rust by skavi on Friday December 13, 2024 @05:20PM (#42412870)
The FromIterator impl for Vec is specialized with unsafe code for these cases.

FromIterator is the trait that the collect method uses.

Specialization isn’t a stable feature in Rust, but is used extensively in the standard library.

There are no comments on this comment yet.