diff options
Diffstat (limited to 'libs/util')
-rw-r--r-- | libs/util/include/util.h | 10 | ||||
-rw-r--r-- | libs/util/util.layout | 34 |
2 files changed, 24 insertions, 20 deletions
diff --git a/libs/util/include/util.h b/libs/util/include/util.h index daa9b8f..e0855db 100644 --- a/libs/util/include/util.h +++ b/libs/util/include/util.h @@ -26,9 +26,13 @@ #define UTIL_H #include <stdlib.h> -#define FREE(m) { void *_tmp_ = m; m = NULL; free(_tmp_); } -#define TO_STRING(s) #s -#define EVER ;; +#define FREE(m) { void *_tmp_ = m; m = NULL; free(_tmp_); } +#define TO_STRING(s) #s +#define EVER ;; + +#define ASSERT_IS(rv, x) if (x != rv) { fprintf(stderr, "assertation failed at %s #%d\n",__FILE__,__LINE__); exit(-1); } +#define ASSERT_NOT(rv, x) if (x == rv) { fprintf(stderr, "assertation failed at %s #%d\n",__FILE__,__LINE__); exit(-1); } +#define FAIL(s) { fprintf(stderr, s); exit(-1); } extern const char * skipWhitespace(const char *Buffer); extern const char *getWord(char *buf, int bufSize, const char *src); diff --git a/libs/util/util.layout b/libs/util/util.layout index 7fa0f25..c12bb95 100644 --- a/libs/util/util.layout +++ b/libs/util/util.layout @@ -1,9 +1,9 @@ <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <CodeBlocks_layout_file> <ActiveTarget name="Debug" /> - <File name="src/JSonWriter.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="src/ManagedMap.cc" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1655" topLine="3" /> + <Cursor1 position="0" topLine="0" /> </Cursor> </File> <File name="include/ManagedMap.h" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> @@ -11,44 +11,44 @@ <Cursor1 position="0" topLine="0" /> </Cursor> </File> - <File name="src/Codec.cc" open="0" top="0" tabpos="9" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="src/StringBuilder.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1327" topLine="0" /> + <Cursor1 position="1953" topLine="59" /> </Cursor> </File> - <File name="include/ManagedVector.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="include/Codec.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="0" topLine="0" /> + <Cursor1 position="1385" topLine="0" /> </Cursor> </File> - <File name="include/StringBuilder.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="src/Codec.cc" open="0" top="0" tabpos="9" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1959" topLine="0" /> + <Cursor1 position="1327" topLine="0" /> </Cursor> </File> - <File name="src/StringBuilder.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="include/JSonWriter.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1953" topLine="59" /> + <Cursor1 position="1532" topLine="0" /> </Cursor> </File> - <File name="include/JSonWriter.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="src/AbstractListAssembler.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1532" topLine="0" /> + <Cursor1 position="0" topLine="0" /> </Cursor> </File> - <File name="src/ManagedMap.cc" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="include/ManagedVector.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> <Cursor1 position="0" topLine="0" /> </Cursor> </File> - <File name="include/Codec.h" open="0" top="0" tabpos="8" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="include/StringBuilder.h" open="0" top="0" tabpos="2" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="1385" topLine="0" /> + <Cursor1 position="1959" topLine="0" /> </Cursor> </File> - <File name="src/AbstractListAssembler.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> + <File name="src/JSonWriter.cc" open="0" top="0" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> <Cursor> - <Cursor1 position="0" topLine="0" /> + <Cursor1 position="1655" topLine="3" /> </Cursor> </File> </CodeBlocks_layout_file> |