bevy/crates/bevy_render
Alix Bott 728c5b98d4
Fix overflow in RenderLayers::iter_layers (#14264)
# Objective

- Fixes overflow when calling `RenderLayers::iter_layers` on layers of
the form `k * 64 - 1`
- Causes a panic in debug mode, and an infinite iterator in release mode

## Solution

- Use `u64::checked_shr` instead of `>>=`

## Testing

- Added a test case for this: `render_layer_iter_no_overflow`
2024-08-02 19:17:57 +02:00
..
macros Release 0.14.0 version bump (#14126) 2024-07-03 18:22:10 -07:00
src Fix overflow in RenderLayers::iter_layers (#14264) 2024-08-02 19:17:57 +02:00
Cargo.toml Release 0.14.0 version bump (#14126) 2024-07-03 18:22:10 -07:00
README.md Add README.md to all crates (#13184) 2024-05-02 18:56:00 +00:00

Bevy Render

License Crates.io Downloads Docs Discord