includes: Switch over to import statements (#224)

* Update includes and patterns to new import system

* Update namespaces to new syntax
This commit is contained in:
Nik
2024-02-25 22:04:41 +01:00
committed by GitHub
parent 3f44a743e8
commit f70b7066b9
128 changed files with 298 additions and 298 deletions

View File

@@ -1,12 +1,12 @@
#pragma once
#include <hex/impl/imhex_check.pat>
import hex.impl.imhex_check;
/*!
Core intrinsic functions to interact with the ImHex Hex Editor
*/
namespace hex::core {
namespace auto hex::core {
/**
A type representing a selection in the hex editor

View File

@@ -1,14 +1,14 @@
#pragma once
#include <hex/impl/imhex_check.pat>
import hex.impl.imhex_check;
#include <std/mem.pat>
import std.mem;
/*!
Library to allow decoding of more complex values
*/
namespace hex::dec {
namespace auto hex::dec {
/**
Demangles a mangled name into a human readable name

View File

@@ -1,12 +1,12 @@
#pragma once
#include <hex/impl/imhex_check.pat>
import hex.impl.imhex_check;
/*!
Library to do HTTP requests
*/
namespace hex::http {
namespace auto hex::http {
/**
Performs a HTTP GET request to the given URL and returns the response body

View File

@@ -1,12 +1,12 @@
#pragma once
#include <hex/impl/imhex_check.pat>
import hex.impl.imhex_check;
/*!
Library to interact with the currently loaded provider.
*/
namespace hex::prv {
namespace auto hex::prv {
/**

View File

@@ -1,16 +1,16 @@
#pragma once
#include <std/io.pat>
#include <std/mem.pat>
import std.io;
import std.mem;
#include <hex/impl/imhex_check.pat>
#include <hex/dec.pat>
import hex.impl.imhex_check;
import hex.dec;
/*!
Types to automatically decode mangled names
*/
namespace hex::type {
namespace auto hex::type {
/**
A mangled name string that gets demangled when displayed

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/sys.pat>
import std.sys;
/*!
The array library contains a helper type to make it easier to create multi-dimensional arrays
and pass arrays to functions as parameters.
*/
namespace std {
namespace auto std {
/**
Simple one dimensional array wrapper

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/limits.pat>
import std.limits;
/*!
This library contains various helper functions for common bit operations.
*/
namespace std::bit {
namespace auto std::bit {
/**
Calculates the number of 1 bits in a given number

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/mem.pat>
import std.mem;
/*!
The core library contains intrinsics and "compiler magic" functions that
get extra help from the runtime to fulfill their purpose.
*/
namespace std::core {
namespace auto std::core {
/**
The layout order of each field after byte-endianness has been handled.

View File

@@ -5,7 +5,7 @@
of ASCII characters.
*/
namespace std::ctype {
namespace auto std::ctype {
/**
Checks if the given character `c` is a digit between '0' and '9'

View File

@@ -7,7 +7,7 @@
**These functions are considered dangerous and require the user to manually permit them**
*/
namespace std::file {
namespace auto std::file {
/**
A handle representing a file that has been opened

View File

@@ -4,7 +4,7 @@
Library for doing arithmetic with fixed point numbers and converting them from/to floating point numbers.
*/
namespace std::fxpt {
namespace auto std::fxpt {
/**
A fixed point value

View File

@@ -4,7 +4,7 @@
The hash library contains various data hash functions
*/
namespace std::hash {
namespace auto std::hash {
/**
Calculates the CRC32 hash of the bytes inside of a given pattern

View File

@@ -4,7 +4,7 @@
The IO library allows formatting strings and outputting text to the console
*/
namespace std {
namespace auto std {
/**
Formats the given arguments using the format string and prints the result to the console

View File

@@ -4,7 +4,7 @@
Library to calculate the minimum and maximum values that fit into a given data type
*/
namespace std::limits {
namespace auto std::limits {
/**
Returns the minimum value that can be stored in a `u8`.

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/mem.pat>
import std.mem;
/*!
Library containing more advanced mathematical operations.
*/
namespace std::math {
namespace auto std::math {
/**
Compares the values `a` and `b` with each other and returns the smaller of the two

View File

@@ -4,7 +4,7 @@
Library for doing raw memory accesses and other low-level operations.
*/
namespace std::mem {
namespace auto std::mem {
namespace impl {

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/mem.pat>
import std.mem;
/*!
The Pointer library contains helper functions to deal with pointer types.
The `relative_to` functions are meant to be used with the `[[pointer_base]]` attribute
*/
namespace std::ptr {
namespace auto std::ptr {
/**
Use the offset of the current pointer as start address

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/limits.pat>
import std.limits;
/*!
Library to generate random numbers. Supports various different distribution types.
*/
namespace std::random {
namespace auto std::random {
/**
Represents the type of distribution to use to generate a random number

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Libray to interact with strings.
*/
namespace std::string {
namespace auto std::string {
/**
Base type for sized strings. Represents a string with its size preceeding it.

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Basic helper functions
*/
namespace std {
namespace auto std {
/**
Asserts that a given value is true. If it's not, abort evaluation and print the given message to the console

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Library to handle time and date related operations.
*/
namespace std::time {
namespace auto std::time {
/**
A structured representation of a time and date.

View File

@@ -1,14 +1,14 @@
#pragma once
#include <std/io.pat>
#include <std/math.pat>
import std.io;
import std.math;
/*!
Types used to change the base of the displayed integer value.
Used like `type::Hex<u32> hexNumber;`, `type::Oct<u16> octalNumber;`
*/
namespace type {
namespace auto type {
/**
Integer type representing a Hexadecimal value. Displays its value in hexadecimal format.

View File

@@ -1,12 +1,12 @@
#include <std/io.pat>
#include <std/string.pat>
#include <std/mem.pat>
import std.io;
import std.string;
import std.mem;
/*!
Type representing a Base64 encoded string
*/
namespace type {
namespace auto type {
/**
Type representing a Base64 encoded string

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Type to decode a BCD (Binary Coded Decimal) number
*/
namespace type {
namespace auto type {
/**
Decodes a BCD value where one byte represents a single digit

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Types to display single bytes using various different representations
*/
namespace type {
namespace auto type {
/**
Type visualizing the value of each individual bit

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/io.pat>
#include <std/core.pat>
import std.io;
import std.core;
/*!
Types representing RGB or RGBA colors. The decoded color will be displayed in their color field
*/
namespace type {
namespace auto type {
/**
Type representing a generic RGBA color with a variable number of bits for each color

View File

@@ -1,14 +1,14 @@
#pragma once
#include <std/io.pat>
#include <std/math.pat>
#include <std/mem.pat>
import std.io;
import std.math;
import std.mem;
/*!
Type representing a 16 bit half precision floating point number
*/
namespace type {
namespace auto type {
/**
Type representing a 16 bit half precision floating point number

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Types to deal with UUIDs (Universally Unique Identifiers) / GUIDs (Globally Unique Identifiers) as described in RFC 4122
*/
namespace type {
namespace auto type {
/**
Type representing a GUID value

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/io.pat>
#include <std/string.pat>
import std.io;
import std.string;
/*!
Types used to decode IP addresses
*/
namespace type {
namespace auto type {
/**
A 4 byte IPv4 Address as described in RFC 791

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/io.pat>
#include <std/mem.pat>
import std.io;
import std.mem;
/*!
Types used to decode Little Endian Base 128 numbers used to store large numbers as space efficiently as possible
*/
namespace type {
namespace auto type {
/**
Base LEB128 type. Use `uLEB128` and `sLEB128` instead.

View File

@@ -1,12 +1,12 @@
#pragma once
#include <std/io.pat>
import std.io;
/*!
Types used to decode MAC Addresses
*/
namespace type {
namespace auto type {
/**
A MAC Address as used in the Internet Protocol

View File

@@ -1,13 +1,13 @@
#include <std/string.pat>
#include <std/sys.pat>
#include <std/io.pat>
#include <std/ctype.pat>
import std.string;
import std.sys;
import std.io;
import std.ctype;
/*!
Types used to parse and enforce specific magic numbers
*/
namespace type
namespace auto type
{
fn fm(ref auto value)
{

View File

@@ -1,10 +1,10 @@
#include <std/mem.pat>
import std.mem;
/*!
Types dealing with various kinds of resource paths
*/
namespace type {
namespace auto type {
/**
Type representing a single path segment. Use the `Path` type instead of using this on its own

View File

@@ -1,10 +1,10 @@
#include <std/io.pat>
import std.io;
/*!
Types used to pretty print size values
*/
namespace type {
namespace auto type {
/**
A generic size type which displays its value in Bytes (or kiB, MiB, GiB, TiB, PiB, EiB if larger)

View File

@@ -1,13 +1,13 @@
#pragma once
#include <std/io.pat>
#include <std/time.pat>
import std.io;
import std.time;
/*!
Types used to decode various different time formats
*/
namespace type {
namespace auto type {
/**
A 32 bit Unix time value

View File

@@ -5,7 +5,7 @@
*/
// Explicitly don't add these types to the `type` namespace for usability
// namespace type {
// namespace auto type {
// using char = s8;
using byte = s8;

View File

@@ -5,7 +5,7 @@
*/
// Explicitly don't add these types to the `type` namespace for usability
// namespace type {
// namespace auto type {
using uint8_t = u8;
using uint16_t = u16;

View File

@@ -5,7 +5,7 @@
*/
// Explicitly don't add these types to the `type` namespace for usability
// namespace type {
// namespace auto type {
using le16 = le u16;
using be16 = be u16;

View File

@@ -5,7 +5,7 @@
*/
// Explicitly don't add these types to the `type` namespace for usability
// namespace type {
// namespace auto type {
// using u8 = u8;
// using u16 = u16;

View File

@@ -5,7 +5,7 @@
*/
// Explicitly don't add these types to the `type` namespace for usability
// namespace type {
// namespace auto type {
using BYTE = u8;
using WORD = u16;

View File

@@ -1,8 +1,8 @@
#pragma author WerWolv
#pragma description Autodesk 3DS Max Model file
#include <std/io.pat>
#include <type/base.pat>
import std.io;
import type.base;
#pragma MIME image/x-3ds

View File

@@ -1,8 +1,8 @@
#pragma description 7z File Format
#include <std/io.pat>
#include <std/mem.pat>
#include <std/math.pat>
import std.io;
import std.mem;
import std.math;
enum Type:u8{

View File

@@ -2,9 +2,9 @@
#pragma description Crash Bandicoot - Back in Time (fan game) User created level format
// Supports all versions till 0.94c, newer versions might be compatible!
#include <type/magic.pat>
#include <std/string.pat>
#include <std/array.pat>
import type.magic;
import std.string;
import std.array;
struct Header {

View File

@@ -3,8 +3,8 @@
#pragma endian little
#include <std/io.pat>
#include <std/sys.pat>
import std.io;
import std.sys;
#define ATMOSPHERE_REBOOT_TO_FATAL_MAGIC "AFE2"
#define ATMOSPHERE_REBOOT_TO_FATAL_MAGIC_1 "AFE1"

View File

@@ -3,9 +3,9 @@
#pragma MIME application/x-archive
#include <std/string.pat>
#include <std/mem.pat>
#include <std/sys.pat>
import std.string;
import std.mem;
import std.sys;
struct ARFile {
char file_name[16];

View File

@@ -3,8 +3,8 @@
#pragma endian little
#include <std/io.pat>
#include <std/mem.pat>
import std.io;
import std.mem;
#define VTOR 0x00000000
#define EXTERNAL_INTERRUPT_COUNT 64

View File

@@ -3,9 +3,9 @@
#pragma MIME application/x-bittorrent
#include <std/ctype.pat>
#include <std/mem.pat>
#include <std/string.pat>
import std.ctype;
import std.mem;
import std.string;
namespace bencode {

View File

@@ -2,7 +2,7 @@
#pragma MIME image/bmp
#pragma endian little
#include <std/mem.pat>
import std.mem;
struct BitmapFileHeader {
u8 bfType[2];

View File

@@ -1,7 +1,7 @@
#include <std/math.pat>
#include <std/core.pat>
#include <type/magic.pat>
#include <type/time.pat>
import std.math;
import std.core;
import type.magic;
import type.time;
using CFBinaryPlistObject;

View File

@@ -3,8 +3,8 @@
#pragma MIME application/bson
#include <std/mem.pat>
#include <type/time.pat>
import std.mem;
import type.time;
enum Type : u8 {
Double = 0x01,

View File

@@ -1,8 +1,8 @@
#pragma description GoldSrc engine maps format (used in Half-Life 1)
#include <std/ptr.pat>
#include <std/mem.pat>
#include <std/sys.pat>
import std.ptr;
import std.mem;
import std.sys;
#pragma endian little

View File

@@ -1,11 +1,11 @@
#pragma author WerWolv
#pragma description Windows HtmlHelp Data (ITSF / CHM)
#include <type/magic.pat>
#include <type/size.pat>
#include <type/guid.pat>
#include <type/leb128.pat>
#include <std/sys.pat>
import type.magic;
import type.size;
import type.guid;
import type.leb128;
import std.sys;
enum WindowsLanguageId : u32 {
Arabic_SaudiArabia = 0x401,

View File

@@ -3,8 +3,8 @@
#pragma MIME application/x-coff
#include <type/time.pat>
#include <type/size.pat>
import type.time;
import type.size;
enum Machine : u16 {
Unknown = 0x0000,

View File

@@ -1,12 +1,12 @@
#pragma author WerWolv
#pragma description Old Binary CPIO Format
#include <type/base.pat>
import type.base;
#include <std/time.pat>
#include <std/core.pat>
#include <std/sys.pat>
#include <std/mem.pat>
import std.time;
import std.core;
import std.sys;
import std.mem;
#pragma MIME application/x-cpio

View File

@@ -1,6 +1,6 @@
#pragma description Dalvik EXecutable Format
#include <type/leb128.pat>
import type.leb128;
struct header_item {
u8 magic[8];

View File

@@ -3,12 +3,12 @@
#pragma MIME application/dicom
#pragma endian little
#include <std/core.pat>
#include <std/io.pat>
#include <std/mem.pat>
#include <std/string.pat>
#include <std/sys.pat>
#include <type/magic.pat>
import std.core;
import std.io;
import std.mem;
import std.string;
import std.sys;
import type.magic;
u32 UNDEFINED_LENGTH = 0xffffffff;

View File

@@ -2,10 +2,10 @@
#pragma endian big
#include <type/magic.pat>
#include <type/size.pat>
#include <type/guid.pat>
#include <std/mem.pat>
import type.magic;
import type.size;
import type.guid;
import std.mem;
// Parse DMG Structure per http://newosxbook.com/DMG.html
//

View File

@@ -2,7 +2,7 @@
// Apple macOS .DS_Store format
#pragma endian big
#include <std/io.pat>
import std.io;
struct RecordEntry {
u32 length;

View File

@@ -7,9 +7,9 @@
#pragma MIME application/x-object
#pragma MIME application/x-sharedlib
#include <std/core.pat>
#include <std/io.pat>
#include <std/mem.pat>
import std.core;
import std.io;
import std.mem;
using BitfieldOrder = std::core::BitfieldOrder;

View File

@@ -3,12 +3,12 @@
#pragma endian big
#include <std/sys.pat>
#include <std/io.pat>
#include <std/core.pat>
import std.sys;
import std.io;
import std.core;
#include <type/magic.pat>
#include <type/size.pat>
import type.magic;
import type.size;
// These are used in order for the children to be able to find strings
u64 fdt_addr;

View File

@@ -1,9 +1,9 @@
#pragma author WerWolv
#pragma description Free Lossless Audio Codec, FLAC Audio Format
#include <std/sys.pat>
#include <std/core.pat>
#include <std/io.pat>
import std.sys;
import std.core;
import std.io;
#pragma endian big

View File

@@ -1,7 +1,7 @@
#pragma author WerWolv
#pragma description Drive File System
#include <std/io.pat>
import std.io;
struct DiskTimeStamp {
u8 seconds, minutes, hours;

View File

@@ -3,9 +3,9 @@
#pragma MIME application/x-gameboy-rom
#include <type/size.pat>
#include <std/string.pat>
#include <std/mem.pat>
import type.size;
import std.string;
import std.mem;
bool uppercaseROMFeatures in;
bool brandedROMFeatures in;

View File

@@ -13,13 +13,13 @@
#define EXTENSION_INTRODUCER_MAGIC 0x21
#define GIF_TRAILER_MAGIC 0x3B
#include <std/io.pat>
#include <std/core.pat>
#include <std/mem.pat>
#include <std/string.pat>
#include <std/math.pat>
import std.io;
import std.core;
import std.mem;
import std.string;
import std.math;
#include <type/magic.pat>
import type.magic;
bitfield GCT_Flags {
size : 3 [[comment("physical size = 2^(flags.size + 1)")]];

View File

@@ -22,8 +22,8 @@
* SOFTWARE.
*/
#include <std/mem.pat>
#include <std/io.pat>
import std.mem;
import std.io;
/**
* @brief The glTF magic section.

View File

@@ -3,10 +3,10 @@
#pragma MIME application/gzip
#include <type/time.pat>
#include <type/size.pat>
#include <std/core.pat>
#include <std/mem.pat>
import type.time;
import type.size;
import std.core;
import std.mem;
using BitfieldOrder = std::core::BitfieldOrder;

View File

@@ -1,6 +1,6 @@
#include <std/mem.pat>
#include <std/io.pat>
#include <std/string.pat>
import std.mem;
import std.io;
import std.string;
struct Header {
u32 magic;

View File

@@ -1,10 +1,10 @@
#pragma author Surasia
#pragma description Halo Infinite HavokScript 5.1 "luas" file
#include <std/io.pat>
#include <std/mem.pat>
#include <std/core.pat>
#include <std/string.pat>
import std.io;
import std.mem;
import std.core;
import std.string;
struct String32 {
s32 length;

View File

@@ -3,7 +3,7 @@
#pragma endian little
#include <std/sys.pat>
import std.sys;
#pragma MIME image/vnd.microsoft.icon
#pragma MIME image/x-icon

View File

@@ -2,7 +2,7 @@
#pragma MIME audio/mpeg
#include <std/mem.pat>
import std.mem;
namespace v1 {

View File

@@ -8,7 +8,7 @@
*/
#pragma endian big
#include <std/mem.pat>
import std.mem;
enum FileType: u16 {
Data = 0x3030,

View File

@@ -3,8 +3,8 @@
#pragma endian big
#include <std/sys.pat>
#include <std/io.pat>
import std.sys;
import std.io;
struct MAC {
u8 octets[6];

View File

@@ -3,8 +3,8 @@
#pragma endian big
#include <std/mem.pat>
#include <std/string.pat>
import std.mem;
import std.string;
struct Hunk {
u24 offset;

View File

@@ -2,7 +2,7 @@
#pragma endian little
#include <std/io.pat>
import std.io;
enum VolumeDescriptorTypes : u8 {
BootRecord,

View File

@@ -5,11 +5,11 @@
#pragma pattern_limit 100000000
#pragma MIME application/x-java-applet
#include <std/string.pat>
#include <std/math.pat>
#include <std/core.pat>
#include <std/io.pat>
#include <std/sys.pat>
import std.string;
import std.math;
import std.core;
import std.io;
import std.sys;
using BitfieldOrder = std::core::BitfieldOrder;

View File

@@ -1,9 +1,9 @@
#pragma author WerWolv
#pragma description JPEG Image Format
#include <std/io.pat>
#include <std/mem.pat>
#include <type/magic.pat>
import std.io;
import std.mem;
import type.magic;
#pragma endian big
#pragma MIME image/jpeg

View File

@@ -3,9 +3,9 @@
#pragma MIME application/x-ms-shortcut
#include <std/core.pat>
#include <type/guid.pat>
#include <type/size.pat>
import std.core;
import type.guid;
import type.size;
using BitfieldOrder = std::core::BitfieldOrder;

View File

@@ -1,7 +1,7 @@
#pragma description Lua 5.4 bytecode
#include <std/io.pat>
#include <std/mem.pat>
import std.io;
import std.mem;
namespace impl {

View File

@@ -3,7 +3,7 @@
#pragma MIME application/x-mach-binary
#include <type/size.pat>
import type.size;
enum Magic : u32 {
_32BitMagic = 0xFEEDFACE,

View File

@@ -1,7 +1,7 @@
#pragma description Mechanized Assault and Exploration v1.04 (strategy game) save file format
#include <std/sys.pat>
#include <std/mem.pat>
import std.sys;
import std.mem;
#pragma array_limit 12544
#pragma pattern_limit 2000000

View File

@@ -1,6 +1,6 @@
#pragma description MIDI header, event fields provided
#include <std/core.pat>
import std.core;
#pragma MIME audio/midi
#pragma endian big

View File

@@ -3,9 +3,9 @@
#pragma MIME application/x-dmp
#include <type/time.pat>
#include <type/types/win32.pat>
#include <type/size.pat>
import type.time;
import type/types.win32;
import type.size;
using RVA = ULONG32;
using RVA64 = ULONG64;

View File

@@ -6,9 +6,9 @@
#pragma MIME video/mp4
#pragma MIME application/mp4
#include <std/io.pat>
#include <std/mem.pat>
#include <std/string.pat>
import std.io;
import std.mem;
import std.string;
fn to_string(auto var) {
return str(var);

View File

@@ -3,8 +3,8 @@
#pragma endian little
#include <std/sys.pat>
#include <std/io.pat>
import std.sys;
import std.io;
struct ApplicationTitle {
char name[0x200];

View File

@@ -1,7 +1,7 @@
#pragma author WerWolv
#pragma description Minecraft NBT format
#include <std/sys.pat>
import std.sys;
#pragma endian big

View File

@@ -1,6 +1,6 @@
#pragma description NE header and Standard NE fields
#include <std/mem.pat>
import std.mem;
struct DOSHeader {
char signature[2];

View File

@@ -1,8 +1,8 @@
#pragma author gmestanley
#pragma description .nes file format
#include <std/mem.pat>
#include <std/string.pat>
import std.mem;
import std.string;
bitfield iNES07Flags {
mirroringIsVertical : 1;

View File

@@ -1,8 +1,8 @@
#pragma author WerWolv
#pragma description Nintendo Switch NRO files
#include <std/io.pat>
#include <std/sys.pat>
import std.io;
import std.sys;
struct MOD0 {
char magic[4];

View File

@@ -1,7 +1,7 @@
#pragma author WerWolv
#pragma description NTAG213/NTAG215/NTAG216, NFC Forum Type 2 Tag compliant IC
#include <std/core.pat>
import std.core;
using BitfieldOrder = std::core::BitfieldOrder;

View File

@@ -3,8 +3,8 @@
#pragma MIME audio/ogg
#include <std/core.pat>
#include <std/mem.pat>
import std.core;
import std.mem;
bitfield HeaderType {
Continuation : 1;

View File

@@ -6,8 +6,8 @@
//
// SPDX-License-Identifier: GPL-2.0-or-later
#include <std/mem.pat>
#include <type/magic.pat>
import std.mem;
import type.magic;
#pragma endian big

View File

@@ -1,6 +1,6 @@
#pragma description pcap header and packets
#include <std/mem.pat>
import std.mem;
#pragma MIME application/vnd.tcpdump.pcap
enum network_type : u32 {

View File

@@ -3,7 +3,7 @@
#pragma MIME application/x-pcx
#include <std/io.pat>
import std.io;
enum Encoding : u8 {
NoEncoding = 0x00,

View File

@@ -5,10 +5,10 @@
#pragma MIME application/x-msdownload
#pragma MIME application/vnd.microsoft.portable-executable
#include <std/core.pat>
#include <std/string.pat>
#include <type/guid.pat>
#include <type/time.pat>
import std.core;
import std.string;
import type.guid;
import type.time;
struct DOSHeader {
char signature[2] [[hex::spec_name("e_magic")]];

View File

@@ -1,10 +1,10 @@
#pragma author WerWolv
#pragma description Nintendo Switch PFS0 archive (NSP files)
#include <type/magic.pat>
#include <type/size.pat>
import type.magic;
import type.size;
#include <std/core.pat>
import std.core;
struct FileEntry {
u64 dataOffset;

View File

@@ -3,7 +3,7 @@
#pragma MIME image/png
#pragma endian big
#include <std/mem.pat>
import std.mem;
struct header_t {
u8 highBitByte;

View File

@@ -1,10 +1,10 @@
#pragma author WerWolv
#pragma description Google Protobuf encoding
#include <std/core.pat>
#include <std/mem.pat>
import std.core;
import std.mem;
#include <type/leb128.pat>
import type.leb128;
struct ZigZag32 {
u32 value;

View File

@@ -1,7 +1,7 @@
#pragma description Python bytecode files
#include <type/time.pat>
#include <std/mem.pat>
import type.time;
import std.mem;
#define FLAG_REF 0x80
#define TYPE_NULL '0'

View File

@@ -2,7 +2,7 @@
#pragma endian big
#include <std/mem.pat>
import std.mem;
// Reference:
// https://pyinstaller.org/en/stable/advanced-topics.html

View File

@@ -3,7 +3,7 @@
#pragma MIME image/qoi
#pragma endian big
#include <std/mem.pat>
import std.mem;
namespace qoi {

Some files were not shown because too many files have changed in this diff Show More