diff --git a/README.md b/README.md index 419f84d..8b4e292 100644 --- a/README.md +++ b/README.md @@ -81,5 +81,8 @@ $ ./planck < bootstrap.fs example/fib.fs | < | less | ( a b -- c ) | c = (a < b) | | u | uless | ( a b -- c ) | c = (a unsigned< b) | | = | equal | ( a b -- c ) | c = (a == b) | +| { | shl | ( a b -- c ) | c = a << b (logical) | +| } | shr | ( a b -- c ) | c = a >> b (logical) | +| ) | sar | ( a b -- c ) | c = a >> b (arithmetic) | | v | argv | ( -- a-addr u ) | argv and argc | | V | impl | ( -- c-addr ) | Implementation String | diff --git a/bootstrap.fs b/bootstrap.fs index 73584b4..b7ec23b 100644 --- a/bootstrap.fs +++ b/bootstrap.fs @@ -56,6 +56,9 @@ l! \ '<' ( a b -- c ) c = (a < b) \ 'u' ( a b -- c ) c = (a unsigned< b) \ '=' ( a b -- c ) c = (a == b) +\ '{' ( a b -- c ) c = a << b (logical) +\ '}' ( a b -- c ) c = a >> b (logical) +\ ')' ( a b -- c ) c = a >> b (arithmetic) \ 'v' ( -- a-addr u ) argv and argc \ 'V' ( -- c-addr ) Version text