aboutsummaryrefslogtreecommitdiffstats
path: root/Source/lib/definitions.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/lib/definitions.h')
-rw-r--r--Source/lib/definitions.h19
1 files changed, 17 insertions, 2 deletions
diff --git a/Source/lib/definitions.h b/Source/lib/definitions.h
index 2acec8d0a..11bd04f74 100644
--- a/Source/lib/definitions.h
+++ b/Source/lib/definitions.h
@@ -202,12 +202,27 @@
*/
#define POS printf("%s, line %d\n", __FILE__, __LINE__)
+
+
+
/**
- * Papping entry which defines the end of a mapping_t array.
+ * Macro to allocate a type as chunk_t.
+ *
+ * @param thing object on which a sizeof is performed
+ * @return chunk_t pointing to allocated memory
*/
-#define MAPPING_END (-1)
+#define malloc_thing(thing) ((thing*)malloc(sizeof(thing)))
+
+
+
+
+/**
+ * Mapping entry which defines the end of a mapping_t array.
+ */
+#define MAPPING_END (-1)
+
typedef struct mapping_t mapping_t;
/**