mirror of
https://github.com/WerWolv/ImHex-Patterns.git
synced 2026-04-02 05:27:40 -05:00
patterns/includes: Update standard library and patterns to support the new bitfields (#102)
* Add `current_bit_offset()` and `read_bits(...)` to `std::mem` * Replace deprecated BitfieldOrder enum values with new clearer names This adds new options named `MostToLeastSignificant` and `LeastToMostSignificant` to replace the old `LeftToRight` and `RightToLeft` names. These names should be much clearer about what they affect and how. * Throw errors when `std::core::(get|set)_bitfield_order()` are called * Update all patterns to work with the new bitfield behaviors
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
#include <std/mem.pat>
|
||||
|
||||
#pragma bitfield_order right_to_left
|
||||
|
||||
struct DOSHeader {
|
||||
char signature[2];
|
||||
u16 lastPageSize;
|
||||
@@ -186,7 +184,7 @@ bitfield SegmentTableFlags {
|
||||
containsRelocationInfo : 1;
|
||||
padding : 1;
|
||||
discardPriority : 4;
|
||||
} [[right_to_left]];
|
||||
};
|
||||
|
||||
struct SegmentTable {
|
||||
u16 segmentDataPointer;
|
||||
|
||||
Reference in New Issue
Block a user