On this page:
3.1 The true? Predicate
true?
3.2 Pattern Matching in Simple Functions
3.3 Abbreviation Macros
loop-forever
async
async-loop
with-semaphore
3.4 Threading Macros
8.12

3 Extra Utilities🔗ℹ

3.1 The true? Predicate🔗ℹ

 (require alexis/bool) package: alexis-util
 (require typed/alexis/bool)

procedure

(true? v)  boolean?

  v : any/c
(true? v)  Boolean
  v : Any
Equivalent to (if v #t #f). Useful for casting values to booleans.

3.2 Pattern Matching in Simple Functions🔗ℹ

 (require alexis/util/match) package: alexis-util

NOTE: This library is deprecated; use match-plus, instead. This module re-exports define/match* from match-plus for backwards-compatibility.

3.3 Abbreviation Macros🔗ℹ

 (require alexis/util/abbreviations) package: alexis-util

This module provides various simple abbreviations to make writing Racket code clearer and easier. These forms should work in both Racket and Typed Racket.

syntax

(loop-forever body)

Equivalent to:
(let loop ()
  body
  (loop))

syntax

(async body)

Equivalent to:

(thread (thunk body))

syntax

(async-loop body)

Equivalent to:

(thread (thunk (loop-forever body)))

syntax

(with-semaphore semaphore-expr body)

Equivalent to:
(call-with-semaphore semaphore-expr
  (thunk body))

3.4 Threading Macros🔗ℹ

 (require alexis/util/threading) package: alexis-util

NOTE: This library is deprecated; use threading, instead. This module re-exports ~>, ~>>, and~>, and~>>, lambda~>, λ~>, lambda~>*, λ~>*, lambda~>>, λ~>>, lambda~>>*, λ~>>*, lambda-and~>, λ-and~>, lambda-and~>*, λ-and~>*, lambda-and~>>, λ-and~>>, lambda-and~>>*, and λ-and~>>* from threading for backwards-compatibility.