Handbook
Glossary
decode-delta ( extended extpos! bias -- extpos' delta )
Vocabulary
punycode
.
private
Inputs
extended
an
object
extpos!
an
object
bias
an
object
Outputs
extpos'
an
object
delta
an
object
Definition
USING:
kernel
math
sequences
;
IN:
punycode.private
::
decode-delta
( extended extpos! bias -- extpos' delta )
0
:>
delta! 1
:>
w! 0
:>
j!
[
j 1
+
j! j bias
threshold
:>
T extpos extended
nth
decode-digit
:>
digit extpos 1
+
extpos! digit w
*
delta
+
delta!
BASE
T
-
w
*
w! digit T
>=
]
loop
extpos delta
;