AWL metatypes list


Int

Integer value.
Anything evaluating to integer. As argument, any scalar value allowed (implicitly coerced to integer).
 

Float

Float value.
Anything evaluating to float. As argument, any scalar value allowed (implicitly coerced to float).
 

Num

Numeric value.
Anything evaluating to integer or float. As argument, any scalar value allowed (implicitly coerced to number).
 

String

String value.
Anything evaluating to string. As argument, any scalar value allowed (implicitly coerced to string).
 

Bool

Boolean value.
Anything treated as boolean condition.
As argument: 0, "" and undef as false; or anything other as true.
As result: exactly 0 (as false) or 1 (as true).
 

Sign

Sign value.
Anything treated as result of comparison.
As argument: any scalar value allowed (implicitly coerced to number, then compared with 0).
As result: exactly -1 (negative/less than), 1 (positive/greater than), or 0 (zero/equal).
 

Scalar

Scalar value.
Anything evaluating to scalar (number or string) value.
 

Range

Integer range.
Range of integers, confined in boundary list (Start, End),
Range includes values, for which Start <= value && value < End (or empty, if Start >= End).
If single scalar value N is supplied, range 0..N is assumed.
 

Mutable

Mutable value.
Anything evaluating to mutable.
(Reports error, if argument is immutable.)
 

List

List value.
Anything evaluating to list (allows all atomic values and undef, as trivial lists).
 

Term

Term value.
Anything evaluating to term expression.
 

Block

Block value.
Anything evaluating to block expression.
 

Array

Array value.
Anything evaluating to array.
(Reports error, if argument is not array.)
 

Hash

Hash value.
Anything evaluating to hash.
(Reports error, if argument is not hash.)
 

Pattern

Pattern value.
Anything evaluating to pattern.
(Allows string, which is implicitly converted to string pattern.)
(Reports error, if argument is not pattern.)
 

Object

Object value.
Anything evaluating to instance of arbitrary class.
(Reports error, if argument is not class instance.)
 

Func

Functor reference.
Anything evaluating to functor reference (including builtins, user functors, classes and virtuals).
 

Class

Class reference.
Subset of Func: anything evaluating to class reference.
 

Virtual

Virtual reference.
Subset of Func: anything evaluating to virtual reference.
 

Stream

Stream reference.
Anything evaluating to input/output stream reference.
 

Any

Any type allowed
No constraints implied.
 

Total: 21 metatypes.



Hosted by uCoz