xor now works as a logical xor.
h3rald h3rald@h3rald.com
Thu, 25 Jun 2026 11:13:30 +0200
4 files changed,
19 insertions(+),
5 deletions(-)
M
releases/480-0.html
→
releases/480-0.html
@@ -2,5 +2,5 @@ <h3 id="v480-0">v480-0 — 2026-06-15</h3>
<h4>Chores</h4> <ul> - <li>Re-released using <a href="https://h3rald.com/conver">Convergent Versioning</a></li> + <li>Re-released using <a href="https://h3rald.com/conver">Convergent Versioning</a>.</li> </ul>
A
releases/490-3.html
@@ -0,0 +1,16 @@
+<h3 id="v490-3">v490-3 — 2026-06-25</h3> + +<h4>Breaking Changes</h4> +<ul> + <li>{{sym-xor}} now works as a logical xor, not a bitwise xor.</li> +</ul> + +<h4>Fixes</h4> +<ul> + <li>Added extra calls to free allocated items in some symbols.</li> +</ul> + +<h4>Chores</h4> +<ul> + <li>Removed unused symbols (<code>debug</code>) and declarations (<code>when</code>, <code>slice</code>).</li> +</ul>
M
src/hex.c
→
src/hex.c
@@ -353,7 +353,6 @@ int hex_symbol_or(hex_context_t *ctx);
int hex_symbol_not(hex_context_t *ctx); int hex_symbol_xor(hex_context_t *ctx); int hex_symbol_cat(hex_context_t *ctx); -int hex_symbol_slice(hex_context_t *ctx); int hex_symbol_len(hex_context_t *ctx); int hex_symbol_get(hex_context_t *ctx); int hex_symbol_index(hex_context_t *ctx);@@ -368,7 +367,6 @@ int hex_symbol_exit(hex_context_t *ctx);
int hex_symbol_exec(hex_context_t *ctx); int hex_symbol_run(hex_context_t *ctx); int hex_symbol_if(hex_context_t *ctx); -int hex_symbol_when(hex_context_t *ctx); int hex_symbol_while(hex_context_t *ctx); int hex_symbol_error(hex_context_t *ctx); int hex_symbol_try(hex_context_t *ctx);@@ -5332,7 +5330,7 @@ return 1;
} if (a->type == HEX_TYPE_INTEGER && b->type == HEX_TYPE_INTEGER) { - int result = hex_push_integer(ctx, a->data.int_value ^ b->data.int_value); + int result = hex_push_integer(ctx, (a->data.int_value && !b->data.int_value) || (!a->data.int_value && b->data.int_value)) ; if (result != 0) { HEX_FREE(ctx, a);
M
src/symbols.c
→
src/symbols.c
@@ -1303,7 +1303,7 @@ return 1;
} if (a->type == HEX_TYPE_INTEGER && b->type == HEX_TYPE_INTEGER) { - int result = hex_push_integer(ctx, a->data.int_value ^ b->data.int_value); + int result = hex_push_integer(ctx, (a->data.int_value && !b->data.int_value) || (!a->data.int_value && b->data.int_value)) ; if (result != 0) { HEX_FREE(ctx, a);