diff --git a/include/lang/pattern_data.hpp b/include/lang/pattern_data.hpp index 3b9faff60..281527cd0 100644 --- a/include/lang/pattern_data.hpp +++ b/include/lang/pattern_data.hpp @@ -336,17 +336,17 @@ namespace hex::lang { void createEntry(prv::Provider* &provider) override { if (this->getSize() == 4) { - float data = 0; + u32 data = 0; provider->read(this->getOffset(), &data, 4); data = hex::changeEndianess(data, 4, this->getEndian()); - this->createDefaultEntry(hex::format("%e (0x%0*lX)", data, this->getSize() * 2, *reinterpret_cast(&data))); + this->createDefaultEntry(hex::format("%e (0x%0*lX)", *reinterpret_cast(&data), this->getSize() * 2, data)); } else if (this->getSize() == 8) { - double data = 0; + u64 data = 0; provider->read(this->getOffset(), &data, 8); data = hex::changeEndianess(data, 8, this->getEndian()); - this->createDefaultEntry(hex::format("%e (0x%0*lX)", data, this->getSize() * 2, *reinterpret_cast(&data))); + this->createDefaultEntry(hex::format("%e (0x%0*lX)", *reinterpret_cast(&data), this->getSize() * 2, data)); } }