From: Michael D. Lowis Date: Sat, 22 Nov 2014 03:49:12 +0000 (-0500) Subject: fixed bug in the comma word and cleaned up the create word X-Git-Url: https://git.mdlowis.com/?a=commitdiff_plain;h=4db2b1ef398fdb6ee730a58db56bd09ab8f14f06;p=projs%2Fonward.git fixed bug in the comma word and cleaned up the create word --- diff --git a/source/onward/onward.c b/source/onward/onward.c index f31b92e..a040f53 100755 --- a/source/onward/onward.c +++ b/source/onward/onward.c @@ -194,15 +194,16 @@ defcode("create", create, &exec, 0u) { ((word_t*)here)->name = name; ((word_t*)here)->code = (value_t*)(((word_t*)here) + 1); /* Update latest and here variables and initialize the code array */ - latest = here; - here = (value_t)(((word_t*)here) + 1); + latest = here; + here += sizeof(word_t); *((value_t*)here) = 0u; } /** Append a word to the latest word definition */ defcode(",", comma, &create, 0u) { - *((value_t*)here++) = onward_aspop(); - *((value_t*)here) = 0u; + *((value_t*)here) = onward_aspop(); + here += sizeof(value_t); + *((value_t*)here) = 0u; } /** Set the interpreter mode to "interpret" */