Next: , Previous: , Up: built-in   [Contents][Index]


6.26 Type of promise objects

Core Type: <promise>
Parent Type: <struct>

Type of promises.

Type constructor on <promise>: <promise> type-constructor thunk

Build and return a new <promise> object using thunk to generate the value. The code:

(delay 3)

is equivalent to:

(new <promise> (lambda () 3))
Type predicate on <promise>: <boolean> type-predicate obj

The type predicate is promise?.

Equality predicate on <promise>: <boolean> equality-predicate this {prom <promise>}

The equality predicate is eq?.

Hash function on <promise>: <non-negative-fixnum> hash-function this

The hash function is promise-hash.

Methods

Method on <promise>: <top> force this

Apply force to the instance and return its return value.