diff --git a/ueforth/common/floats.fs b/ueforth/common/floats.fs index c61bf60..d9410a7 100644 --- a/ueforth/common/floats.fs +++ b/ueforth/common/floats.fs @@ -46,5 +46,7 @@ forth definitions internals : #fs ( r -- ) fdup f0< if fnegate #f+s [char] - hold else #f+s then ; : f. ( r -- ) <# #fs #> type space ; +: f.s ." <" fdepth n. ." > " + fdepth 0 max for aft fp@ r@ sfloats - sf@ f. then next ; forth definitions diff --git a/ueforth/site/common.html b/ueforth/site/common.html index 080551f..d74bdc3 100644 --- a/ueforth/site/common.html +++ b/ueforth/site/common.html @@ -179,11 +179,13 @@ AFLITERAL ( r -- ) FLITERAL ( r -- ) IMMEDIATE FCONSTANT ( r "name" ) -FVARAIABLE ( "name" ) +FVARIABLE ( "name" ) PI ( -- r ) FSQRT ( r r -- r ) + +F.S ( -- ) Print float stack.