chickadee » latch

Outdated egg!

This is an egg for CHICKEN 4, the unsupported old release. You're almost certainly looking for the CHICKEN 5 version of this egg, if it exists.

If it does not exist, there may be equivalent functionality provided by another egg; have a look at the egg index. Otherwise, please consider porting this egg to the current version of CHICKEN.

latch

Introduction

Allows evaluating expressions just once.

Usage

(require-extension latch)

Requirements

matchable

Documentation

(let-once ((IDENTIFIER EXPR) ...) BODY ...)syntax

Binds IDENTIFIER to the result of evaluating EXPR and evaluates BODY. On any subsequent evaluation of the let-once form, the result of EXPR is re-used and evaluation of EXPR is skipped.

(let*-once ((IDENTIFIER EXPR) ...) BODY ...)syntax

Like let-once, but binds sequentially (just like let*).

Author

felix winkelmann

License

This code is placed into the public domain.

Version History

0.1
initial release

Contents »