aldelaro5 / dolphin-memory-engine

A RAM search made specifically to search, monitor and edit the Dolphin emulator's emulated memory
MIT License
158 stars 36 forks source link

Address `-Wfortify-source` warnings. #138

Closed cristian64 closed 1 month ago

cristian64 commented 1 month ago

A number of constexpr checks have been added to the compareMemoryAsNumbersWithType<T>() template function so that the compiler can determine that type conversions are only performed between compatible types (i.e. types of the same width).

In addition, Common::bit_cast is now used for type conversion (instead of raw memcpy()).

-Wfortify-source; previously suppressed; has been re-enabled now. Note that this is a Clang-specific warning type.