Files
rust/library/core/src
bors 27733d46d7 Auto merge of #130887 - Soveu:repeatn, r=scottmcm
Safer implementation of RepeatN

I've seen the "Use MaybeUninit for RepeatN" commit while reading This Week In Rust and immediately thought about something I've written some time ago - https://github.com/Soveu/repeat_finite/blob/master/src/lib.rs.

Using the fact, that `Option` will find niche in `(T, NonZeroUsize)`, we can construct something that has the same size as `(T, usize)` while completely getting rid of `MaybeUninit`.
This leaves only `unsafe` on `TrustedLen`, which is pretty neat.
2025-06-18 03:18:10 +00:00
..
2025-05-26 15:21:03 +08:00
2025-06-12 12:53:14 -04:00
2025-05-12 15:33:37 +02:00
2025-06-13 22:32:15 +02:00
2025-06-09 15:25:26 -05:00
2025-06-11 18:28:05 +02:00
2025-05-12 15:33:37 +02:00
2025-06-05 07:09:16 +00:00
2025-03-08 12:56:00 +01:00
2025-04-16 18:53:40 -07:00
2025-05-12 15:33:30 +02:00
2024-07-29 08:26:52 +10:00
2024-07-29 08:26:52 +10:00
2024-06-11 15:47:00 +02:00
2025-01-20 18:35:32 +01:00
2025-03-26 14:32:35 -04:00
2024-11-27 15:14:54 +00:00
2025-05-12 15:33:37 +02:00
2025-04-09 12:29:59 +01:00
2025-06-02 14:46:19 -07:00
2025-02-18 09:32:44 -08:00