Handbook
Glossary
tag-init-form ( spec -- quot )
Vocabulary
xmode
.
utilities
Inputs
spec
an
object
Outputs
quot
an
object
Definition
USING:
combinators
kernel
namespaces
quotations
sequences
xml.data
;
IN:
xmode.utilities
:
tag-init-form
( spec -- quot )
{
{
[
dup
quotation?
]
[
[
object
get
tag
get
]
prepose
]
}
{
[
dup
length
2
=
]
[
first2
[
[
~quotation~
]
dip
[
~quotation~
when*
object
get
]
curry
compose
]
dip
[
execute
]
curry
compose
]
}
{
[
dup
length
3
=
]
[
first3
[
[
~quotation~
dip
~quotation~
curry
compose
]
dip
[
~quotation~
when*
object
get
]
curry
compose
]
dip
[
execute
]
curry
compose
]
}
}
cond
;