a racket lang-extension for rackjure-like anonymous function literals
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
afl
.gitignore
.travis.yml
README.md
info.rkt

README.md

afl Build Status

a lang-extension for adding rackjure-like anonymous function literals to a language, based on at-exp and rackjure

documentation: https://docs.racket-lang.org/afl/index.html

Example:

#lang afl racket/base
(map #λ(+ % 1) '(1 2 3)) ;=> '(2 3 4)

Comparison with similar packages / alternatives:

Package Example Multi-Args Holes in Sub-exprs?
afl (map #λ(+ % 1) (list 1 2 3)) %1, %2 etc. Yes: #λ(+ (* 3 %) 1)
aful (map #λ(+ % 1) (list 1 2 3)) %1, %2 etc. Yes: #λ(+ (* 3 %) 1)
fancy-app (map (+ _ 1) (list 1 2 3)) _, _ in same order No.
compose-app/fancy-app (map (+ _ 1) (list 1 2 3)) _, _ in same order No, but (+ _ 1 .. * 3 _)
curly-fn (map #{+ % 1} (list 1 2 3)) %1, %2 etc. Yes: #{+ (* 3 %) 1}
rackjure (map #λ(+ % 1) (list 1 2 3)) %1, %2 etc. Yes: #λ(+ (* 3 %) 1)
srfi/26 (map (cut + <> 1) (list 1 2 3)) <>, <> in same order No.