Skip to content

Conversation

@newpavlov
Copy link
Member

No description provided.

@newpavlov newpavlov requested a review from tarcieri September 20, 2025 12:14
@newpavlov
Copy link
Member Author

newpavlov commented Sep 20, 2025

We need to also update the dependent downstream crates, but I think this change should not cause any problems.

@tarcieri
Is there anything in hybrid-array which would help to remove the unsafe code used to transform &[Array<u8, N>] to &[u8]? It's the only unsafe code in the crate. The closes thing which I found is Array::as_flattened (BTW note the typo in docs), but it transforms &Array<Array<T, N>, M>.

@tarcieri
Copy link
Member

@newpavlov we’d need to add something like slice_as_flattened. Also I don’t see the typo?

@newpavlov
Copy link
Member Author

newpavlov commented Sep 20, 2025

Could you add it and cut new v0.4.1 release with it?

I don’t see the typo

The docs contain &Array<Array<T, N>, >> while it should be &Array<Array<T, N>, M>

@newpavlov
Copy link
Member Author

I will merge this PR as-is for now and will open a separate issue for unsafe code removal.

@newpavlov newpavlov merged commit 014d8f0 into master Sep 21, 2025
17 checks passed
@newpavlov newpavlov deleted the block-padding/merge_traits branch September 21, 2025 08:49
newpavlov added a commit that referenced this pull request Oct 6, 2025
### Added
- `Padding::pad_detached` method ([#1225])

### Changed
- Migrated from `generic-array` to `hybrid-array` ([#944])
- Edition changed to 2024 and MSRV bumped to 1.85 ([#1149])
- Merged `RawPadding` and `Padding` traits ([#1217])
- Renamed `UnpadError` to `Error` ([#1225])

### Removed
- `Block` type alias ([#1217])
- `PadType` enum and associated type on the `Padding` trait ([#1225])

[#944]: #944
[#1149]: #1149
[#1217]: #1217
[#1225]: #1225
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.

3 participants