Skip to content

Make Slice::{first,last,split_*} methods const#434

Merged
cuviper merged 2 commits intoindexmap-rs:mainfrom
cuviper:const-slice
Apr 2, 2026
Merged

Make Slice::{first,last,split_*} methods const#434
cuviper merged 2 commits intoindexmap-rs:mainfrom
cuviper:const-slice

Conversation

@cuviper
Copy link
Copy Markdown
Member

@cuviper cuviper commented Apr 2, 2026

It's not terribly useful when we offer no const way to get a non-empty
Slice, but this could help conditionally-const code in downstream
projects, and it's trivial to support.

(Excluding &mut methods for now, as that requires Rust 1.83.)

cuviper added 2 commits April 2, 2026 15:10
It's not terribly useful when we offer no `const` way to get a non-empty
`Slice`, but this could help conditionally-const code in downstream
projects, and it's trivial to support.

(Excluding `&mut` methods for now, as that requires Rust 1.83.)
@cuviper cuviper added this pull request to the merge queue Apr 2, 2026
Merged via the queue into indexmap-rs:main with commit 0b2adfe Apr 2, 2026
16 checks passed
@cuviper cuviper deleted the const-slice branch April 2, 2026 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant