From 25c5eac5e6ca1035db1eddd7bea9ac78531da57e Mon Sep 17 00:00:00 2001 From: David Thompson Date: Thu, 28 Dec 2023 11:23:49 -0500 Subject: Delete manuals! Good riddance! These are hosted on files.dthompson.us now! --- manuals/sly/Miscellaneous_002dUtilities.html | 147 --------------------------- 1 file changed, 147 deletions(-) delete mode 100644 manuals/sly/Miscellaneous_002dUtilities.html (limited to 'manuals/sly/Miscellaneous_002dUtilities.html') diff --git a/manuals/sly/Miscellaneous_002dUtilities.html b/manuals/sly/Miscellaneous_002dUtilities.html deleted file mode 100644 index 7d160f4..0000000 --- a/manuals/sly/Miscellaneous_002dUtilities.html +++ /dev/null @@ -1,147 +0,0 @@ - - - - - -Sly: Miscellaneous-Utilities - - - - - - - - - - - - - - - - - - - - -
-

-Previous: , Up: Utilities   [Contents][Index]

-
-
- -

4.6.3 Miscellaneous

- -
-
(use-modules (sly utils))
-
- -

Miscellaneous helpful procedures. -

-
-
Scheme Syntax: define-guardian name reaper
-

Define a new guardian called name and call reaper when -an object within the guardian is GC’d. Reaping is ensured to happen -from the same thread that is running the game loop. -

- -
-
Scheme Procedure: memoize proc
-

Return a memoizing version of proc. -

- -
-
Scheme Syntax: forever body
-

Evaluate body in an unbounded loop. Useful in coroutines that -have no end. -

- -
-
Scheme Syntax: trampoline proc-name
-

Create a new procedure that applies the procedure bound to -proc-name with all given arguments. -

- -
-
Scheme Syntax: chain* args (proc …) . rest
-

Handy macro for flattening nested procedure calls where the output of -an inner call is the last argument to the outer call. -

-
-
(chain* (list '(1 2) '(3 4))
-  (map +)
-  (fold + 0)) ;; => 10
-
- -
- -
-
Scheme Syntax: chain arg (proc …) . rest
-

Like chain* but for a single argument. -

-
-
(chain '(1 2 3 4)
-  (map 1+)
-  (fold + 0)) ;; => 14
-
- -
- -
-
Scheme Procedure: list->vlist* lst
-

Convert lst and all sub-lists within to vlists. -

- -
-
Scheme Procedure: list->vlist* lst index […]
-

Return the element at index index … in the nested vlist -structure vlist. -

- - - - - - -- cgit v1.2.3