The map-bind Reference Manual

Next: , Previous: , Up: (dir)   [Contents][Index]

The map-bind Reference Manual

This is the map-bind Reference Manual, version 1.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Thu Sep 15 05:34:39 2022 GMT+0.

Table of Contents


1 Introduction

Project's home: http://www.hexstreamsoft.com/projects/map-bind/


MAP-BIND is a macro that allows visual grouping of variables with
their corresponding values (not necessarily 1:1) in calls to mapping
operators when using an inline LAMBDA. It does so in a way that
automatically supports virtually every existing and future mapping
operator, all lambda keywords and FUNCALL/APPLY/MULTIPLE-VALUE-CALL
variations.

It does all this with a surprisingly simple implementation!


(map-bind (multiple-value-call #'map 'vector)
    ((symbol #(a b c))
     (number '(1 2 3))
     ((&rest others &key &allow-other-keys) (values '(d e f) #(4 5 6)))
     ((&aux (plus-ten (+ number 10)))))
  (list (1- number) symbol plus-ten (reverse others)))
==
(multiple-value-call #'map 'vector
                     (lambda (symbol number
                              &rest others &key &allow-other-keys
                              &aux (plus-ten (+ number 10)))
                       (list (1- number) symbol plus-ten (reverse others)))
                     #(a b c)
                     '(1 2 3)
                     (values '(d e f) #(4 5 6)))
=>
#((0 A 11 (4 D)) (1 B 12 (5 E)) (2 C 13 (6 F)))


This library is in the Public Domain.
See the UNLICENSE file for details.


2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 map-bind

MAP-BIND is a macro that allows visual grouping of variables with their corresponding values (not necessarily 1:1) in calls to mapping operators when using an inline LAMBDA. It does so in a way that automatically supports virtually every existing and future mapping operator, all lambda keywords and FUNCALL/APPLY/MULTIPLE-VALUE-CALL variations.

Author

Jean-Philippe Paradis <hexstream@gmail.com>

License

Public Domain

Version

1.0

Source

map-bind.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp   [Contents][Index]

3.1.1 map-bind/map-bind.asd

Source

map-bind.asd.

Parent Component

map-bind (system).

ASDF Systems

map-bind.


3.1.2 map-bind/package.lisp

Source

map-bind.asd.

Parent Component

map-bind (system).

Packages

map-bind.


Previous: , Up: Lisp   [Contents][Index]

3.1.3 map-bind/main.lisp

Dependency

package.lisp (file).

Source

map-bind.asd.

Parent Component

map-bind (system).

Public Interface

map-bind (macro).

Internals

%parse-binding (function).


4 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

4.1 map-bind

Source

package.lisp.

Use List

common-lisp.

Public Interface

map-bind (macro).

Internals

%parse-binding (function).


5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Public Interface


5.1.1 Macros

Macro: map-bind (mapping-call-prologue bindings &body body)
Package

map-bind.

Source

main.lisp.


5.2 Internals


Previous: , Up: Internals   [Contents][Index]

5.2.1 Ordinary functions

Function: %parse-binding (binding)
Package

map-bind.

Source

main.lisp.


Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts


Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   %  
F   M  
Index Entry  Section

%
%parse-binding: Private ordinary functions

F
Function, %parse-binding: Private ordinary functions

M
Macro, map-bind: Public macros
map-bind: Public macros

Jump to:   %  
F   M  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables