From c0fa319c9c34d873b683d5ff535b0c51fc6ec63a Mon Sep 17 00:00:00 2001 From: sforman Date: Sun, 30 Jul 2023 15:42:55 -0700 Subject: [PATCH] Crude type checking. I forget why I was doing "not not" so I made it a little more clear. In practice this is regressive: The built-in "isnt_bool" function should be in the dictionary? Or prohibit type checking and let the bugs flow? Rely on inference to prevent bugs that would pass the non-checking versions of the functions? Hmm... --- implementations/defs.txt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/implementations/defs.txt b/implementations/defs.txt index c211788..f4682da 100644 --- a/implementations/defs.txt +++ b/implementations/defs.txt @@ -126,6 +126,8 @@ _mape popd reverse _map0 [_map1] dipd _map2 _map1 stackd shift _map2 [infrst] cons dipd roll< swons -_\/_ [not not] [not] branch -/\ [not not] ii [pop false] [] branch -\/ [not not] ii [] [pop true] branch \ No newline at end of file +_isnt_bool not not +_isnt_two_bools [_isnt_bool] ii +_\/_ [_isnt_bool] [not] branch +/\ _isnt_two_bools [pop false] [] branch +\/ _isnt_two_bools [] [pop true] branch -- 2.11.0