mirror of
https://github.com/thunderbrewhq/binana.git
synced 2025-12-12 17:52:29 +00:00
feat(binana): no special include directories now, you must pass GHIDRA or IDA as a definition into your preprocessor
This commit is contained in:
parent
de5bdadc78
commit
1042d9fa22
60 changed files with 3132 additions and 589 deletions
|
|
@ -1,31 +1,33 @@
|
|||
#ifndef STORM_LIST_H
|
||||
#define STORM_LIST_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
// to make an object self referential
|
||||
// forward-declare 'struct Object_type' as 'Object_type'
|
||||
// then define 'struct Object_type'
|
||||
|
||||
// TSLink<T>
|
||||
#define STORM_TS_LINK(T) typedef struct TSLink_##T TSLink_##T; \
|
||||
struct TSLink_##T { \
|
||||
TSLink_##T* m_prevlink; \
|
||||
T* m_next; \
|
||||
};
|
||||
|
||||
// TSList<T>
|
||||
// TSLinkedNode<T>
|
||||
#define STORM_TS_LIST(T) \
|
||||
STORM_TS_LINK(T) \
|
||||
typedef struct TSList_##T TSList_##T; \
|
||||
typedef struct TSLinkedNode_##T TSLinkedNode_##T; \
|
||||
struct TSList_##T { \
|
||||
ptrdiff_t m_linkoffset; \
|
||||
TSLink_##T m_terminator; \
|
||||
}; \
|
||||
struct TSLinkedNode_##T { \
|
||||
TSLink_##T m_link; \
|
||||
};
|
||||
|
||||
#ifndef STORM_LIST_H
|
||||
#define STORM_LIST_H
|
||||
|
||||
#include "system/types.h"
|
||||
|
||||
// to make an object self referential
|
||||
// forward-declare 'struct Object_type' as 'Object_type'
|
||||
// then define 'struct Object_type'
|
||||
|
||||
// TSLink<T>
|
||||
#define STORM_TS_LINK(T) typedef struct TSLink_##T TSLink_##T; \
|
||||
struct TSLink_##T { \
|
||||
TSLink_##T* m_prevlink; \
|
||||
T* m_next; \
|
||||
};
|
||||
|
||||
// TSList<T>
|
||||
// TSExplicitList<T>
|
||||
// TSLinkedNode<T>
|
||||
#define STORM_TS_LIST(T) \
|
||||
STORM_TS_LINK(T) \
|
||||
typedef struct TSList_##T TSList_##T; \
|
||||
typedef struct TSList_##T TSExplicitList_##T; \
|
||||
typedef struct TSLinkedNode_##T TSLinkedNode_##T; \
|
||||
struct TSList_##T { \
|
||||
ptrdiff_t m_linkoffset; \
|
||||
TSLink_##T m_terminator; \
|
||||
}; \
|
||||
struct TSLinkedNode_##T { \
|
||||
TSLink_##T m_link; \
|
||||
};
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue