# std.math.lossyCast: fix integer overflow · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/42d75f1a254653cbd4d441b300248c37d5f8d5a2)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 42d75f1a254653cbd4d441b300248c37d5f8d5a2

Requested commit: 42d75f1a254653cbd4d441b300248c37d5f8d5a2

Commit: 42d75f1a254653cbd4d441b300248c37d5f8d5a2

Tree: 92bdfd7f377304e91b72fff0dd3785ae57528039

Author: ominitay

Committer: Veikka Tuominen

## Message

```
std.math.lossyCast: fix integer overflow

Fixes integer overflow caused by cast from maxInt(u32) as an f32 to u32.

```

## Parents

- [b3259b47ad03592a156841c87e69421da05e37f3](https://git.cafe/gitcafe/zig/commit/b3259b47ad03592a156841c87e69421da05e37f3?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/42d75f1a254653cbd4d441b300248c37d5f8d5a2?format=markdown)
