diff --git a/4coder_mem.h b/4coder_mem.h index 057e40d4..5cc0041a 100644 --- a/4coder_mem.h +++ b/4coder_mem.h @@ -2,6 +2,10 @@ #ifndef FCODER_MEM_H #define FCODER_MEM_H +#ifndef Assert +# define Assert(n) do{ if(!(n)){*(int*)0 = 0xA11E;} }while(0) +#endif + struct Partition{ char *base; int32_t pos, max; @@ -78,10 +82,6 @@ This is a very week general purpose allocator system. It should only be used for infrequent large allocations (4K+). */ -//#include -//#include -//#include - enum{ MEM_BUBBLE_FLAG_INIT = 0x0, MEM_BUBBLE_USED = 0x1, diff --git a/4ed_app_target.cpp b/4ed_app_target.cpp index 15193d12..99791dd8 100644 --- a/4ed_app_target.cpp +++ b/4ed_app_target.cpp @@ -9,6 +9,10 @@ // TOP +// TODO(allen): can I get away from this one? +#include +#include "4ed_defines.h" + #include "4coder_custom.h" #define FSTRING_IMPLEMENTATION @@ -17,8 +21,6 @@ #define BUFFER_EXPERIMENT_SCALPEL 0 -#include "4ed_defines.h" - #include "4ed_math.h" #include "4ed_system.h" @@ -26,9 +28,6 @@ #include "4ed.h" -// TODO(allen): can I get away from this one? -#include - #define FCPP_FORBID_MALLOC #include "4cpp_lexer.h" diff --git a/README.txt b/README.txt index 31b75631..9906a45e 100644 --- a/README.txt +++ b/README.txt @@ -1,4 +1,4 @@ -Distribution Date: 20.7.2016 (dd.mm.yyyy) +Distribution Date: 30.8.2016 (dd.mm.yyyy) Thank you for contributing to the 4coder project! diff --git a/win32_4ed.cpp b/win32_4ed.cpp index 2f3791f5..de788c62 100644 --- a/win32_4ed.cpp +++ b/win32_4ed.cpp @@ -9,9 +9,10 @@ // TOP -#if FRED_SUPER +#include +#include "4ed_defines.h" -# include "4ed_defines.h" +#if FRED_SUPER # define FSTRING_IMPLEMENTATION # define FSTRING_C @@ -22,8 +23,6 @@ # include "4coder_style.h" # include "4coder_rect.h" -# include - # include "4coder_mem.h" // TODO(allen): This is duplicated from 4coder_custom.h