This repository has been archived by the owner on Jun 24, 2024. It is now read-only.
Use usize
over i32
where possible
#18
Labels
issue:enhancement
New feature or request
meta:maintenance
Changes that will make it easier for us to maintain code
The original code uses
int
liberally due to C's wonderful integer promotion. I think it's easier for us to understand and less troublesome to index arrays if we offer a uniformusize
interface across the board, and only cast to/fromi32
when required.I made this change in my take and found it to be much less messier and easier to reason about (especially with maintaining non-negativity constraints!), but I'm not sure how much it would impact the implementation here.
The text was updated successfully, but these errors were encountered: