Handbook
Glossary
shape-capacity ( shape -- n )
Vocabulary
arrays
.
shaped
Inputs
shape
an
object
Outputs
n
an
object
Definition
IN:
arrays.shaped
GENERIC:
shape-capacity
( shape -- n )
Methods
USING:
accessors
arrays.shaped
kernel
math
sequences
sequences.deep
;
M:
abnormal-shape
shape-capacity
shape>>
0
swap
[
[
dup
sequence?
[
drop
]
[
+
]
if
]
[
1
+
]
if*
]
deep-each
;
USING:
arrays.shaped
sequences
;
M:
sequence
shape-capacity
check-shape-domain
product
;
USING:
accessors
arrays.shaped
sequences
;
M:
uniform-shape
shape-capacity
shape>>
product
;