| Summary: | Specify Big or Little Endian for multi-byte structure primitives | ||
|---|---|---|---|
| Product: | [Applications] okteta | Reporter: | Aaron Bishop <erroneous> |
| Component: | Structures Tool | Assignee: | Alex Richardson <arichardson.kde> |
| Status: | RESOLVED FIXED | ||
| Severity: | wishlist | CC: | kossebau |
| Priority: | NOR | ||
| Version First Reported In: | unspecified | ||
| Target Milestone: | --- | ||
| Platform: | Arch Linux | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Aaron Bishop
2016-08-26 18:10:26 UTC
You can use <primitive type="uint32" byteOrder="big-endian"\> to get the desired result. Or do you want to be able to have type aliases so that type="uint32-be" refers to that? That is not implemented yet and I'm not sure it makes sense. You could achieve that when using javascript structure definitions (https://userbase.kde.org/Okteta/Writing_structure_definitions): function uint32_be() { var ret = uint32() ret.byteOrder = "big-endian" return ret; } function init() { var mm_example = struct({foo: uint32_be()} return mm_example; } my apologies, I don't know how I missed the byteOrder documentation. No need for another alias. |