This is the cl-punch Reference Manual, version 0.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 05:17:36 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
cl-punch
Scala-like anonymous lambda literal
Windymelt
MIT
# Cl-Punch - Scala-like anonymous lambda literal
[![Quicklisp](http://quickdocs.org/badge/cl-punch.svg)](http://quickdocs.org/cl-punch/)
## Usage
“‘
;; Enable syntax.
(cl-punch:enable-punch-syntax)
;; ^() is converted into (lambda ...) .
;; Each underscore is converted into a lambda argument.
(mapcar ^(* 2 _) ’(1 2 3 4 5))
;; => ’(2 4 6 8 10)
;; One underscore corresponds one argument.
(^(* _ _) 2 3)
;; => 6
;; <_ reuses last argument.
(mapcar ^(if (oddp _) (* 2 <_) <_) ’(1 2 3 4 5))
;; => ’(2 2 6 4 10)
;; _! corresponds one argument but it is brought to top of the argument list.
;; It can be useful when you want to change argument order.
(^(cons _ _!) :a :b)
;; => (:b . :a)
(^(list _! _! _!) 1 2 3)
;; => ’(3 2 1)
“‘
## Installation
WIP: Register to quicklisp
## Author
* Windymelt
## Copyright
Copyright (c) 2018 Windymelt
## License
Licensed under the MIT License.
0.1
cl-syntax
(system).
src
(module).
Modules are listed depth-first from the system components tree.
Files are sorted by type and then listed depth-first from the systems components trees.
cl-punch/src/cl-punch.lisp
src
(module).
enable-punch-syntax
(macro).
punch-reader
(function).
punch-syntax
(special variable).
Packages are listed by definition order.
cl-punch
common-lisp
.
enable-punch-syntax
(macro).
punch-reader
(function).
punch-syntax
(special variable).
Definitions are sorted by export status, category, package, and then by lexicographic order.
A reader which converts _ into lambda argument, <_ into last lambda argument.
Jump to: | E F M P |
---|
Index Entry | Section | ||
---|---|---|---|
| |||
E | |||
enable-punch-syntax : | Public macros | ||
| |||
F | |||
Function, punch-reader : | Public ordinary functions | ||
| |||
M | |||
Macro, enable-punch-syntax : | Public macros | ||
| |||
P | |||
punch-reader : | Public ordinary functions | ||
|
Jump to: | E F M P |
---|
Jump to: | P S |
---|
Index Entry | Section | ||
---|---|---|---|
| |||
P | |||
punch-syntax : | Private special variables | ||
| |||
S | |||
Special Variable, punch-syntax : | Private special variables | ||
|
Jump to: | P S |
---|
Jump to: | C F M P S |
---|
Jump to: | C F M P S |
---|