1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-13 08:35:20 +02:00
Files
luanti/irr/include
sfan5 a00b9cab36 Fix operator[] for vector2d and vector3d being potentially UB (#15977)
We don't have a C++ expert on hand, but taking a pointer to one member
and expecting to access another by an offset is very fishy:
- for one, there could theoretically be padding
- the compiler might assume that we are only writing to that first member

The new code has shown to be free for constant parameter values.
Non-constant ones cause the assembly to have branches (why?), but we don't
use that much.
2025-04-08 22:25:45 +02:00
..
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-09-02 14:50:30 +02:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-12-04 18:20:34 +01:00
2024-09-18 12:19:40 +02:00
2024-11-15 12:21:30 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-12-04 18:20:34 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00
2024-03-26 21:39:02 +01:00