The astonish Reference Manual

Table of Contents

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

The astonish Reference Manual

This is the astonish Reference Manual, version 0.1.0, generated automatically by Declt version 3.0 "Montgomery Scott" on Mon Apr 19 14:08:03 2021 GMT+0.


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

1 Introduction

Astonish

A Common Lisp library for querying and manipulating Lisp ASTs

Usage

TODO

Installation

Will hopefully be in Quicklisp soon?

Proposed Features

select-conses should take a fancy query string that supports OR operations, filtering on cadr, caddr, etc, and should also work on atoms. Maybe something like this: "test . code-of-conduct > is-true, is-false", run on this:

(TEST CODE-OF-CONDUCT "Is the given action unsuitable for the given pet?" (IS-FALSE (PET "Cat")) (IS-FALSE (PET "Dog")) (IS-TRUE (PET "Fish")) (IS-FALSE (PET "Rabbit")) (IS-FALSE (PET "Bird")) (IS-TRUE (PLAY-FETCH "Cat")) (IS-FALSE (PLAY-FETCH "Dog")) (IS-TRUE (PLAY-FETCH "Fish")) (IS-TRUE (PLAY-FETCH "Rabbit")) (IS-TRUE (PLAY-FETCH "Bird"))))

Should give:

(IS-FALSE (PET "Cat")) (IS-FALSE (PET "Dog")) (IS-TRUE (PET "Fish")) (IS-FALSE (PET "Rabbit")) (IS-FALSE (PET "Bird")) (IS-TRUE (PLAY-FETCH "Cat")) (IS-FALSE (PLAY-FETCH "Dog")) (IS-TRUE (PLAY-FETCH "Fish")) (IS-TRUE (PLAY-FETCH "Rabbit")) (IS-TRUE (PLAY-FETCH "Bird"))))


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

2 Systems

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


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

2.1 astonish

Author

Brooks J Rady <b.j.rady@gmail.com>

License

GPLv3

Description

A small library for querying and manipulating Lisp ASTs

Version

0.1.0

Dependencies
Source

astonish.asd (file)

Component

src (module)


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

3 Modules

Modules are listed depth-first from the system components tree.


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

3.1 astonish/src

Parent

astonish (system)

Location

src/

Component

main.lisp (file)


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

4 Files

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


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

4.1 Lisp


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

4.1.1 astonish.asd

Location

astonish.asd

Systems

astonish (system)


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

4.1.2 astonish/src/main.lisp

Parent

src (module)

Location

src/main.lisp

Packages

astonish

Exported Definitions
Internal Definitions

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

5 Packages

Packages are listed by definition order.


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

5.1 astonish

Source

main.lisp (file)

Use List
Exported Definitions
Internal Definitions

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

6 Definitions

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


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

6.1 Exported definitions


Previous: , Up: Exported definitions   [Contents][Index]

6.1.1 Functions

Function: load-forms-from-file FILE &optional PACKAGE

Read forms from a lisp file without any evaluation

Package

astonish

Source

main.lisp (file)

Function: macroexpand-select MACROS FORM

Recursively expand all occurrences of select macros

Package

astonish

Source

main.lisp (file)

Function: select-conses PATH FORMS

Given a path (a list of car’s) and list of forms, return all matching conses. The second return value is the same selection, but inverted

Package

astonish

Source

main.lisp (file)


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

6.2 Internal definitions


Previous: , Up: Internal definitions   [Contents][Index]

6.2.1 Functions

Function: cons-difference A B

Like set-difference, but filters for conses and preserves order

Package

astonish

Source

main.lisp (file)

Function: filter-conses-by-car CAR FORMS

Filter forms so that only ones with the specified car remain

Package

astonish

Source

main.lisp (file)

Function: lisp-file FILE

Adds a .lisp extension to pathnames without an extension

Package

astonish

Source

main.lisp (file)

Function: map-inodes FUNCTION FORM

Maps the given function over all the inner nodes of a tree

Package

astonish

Source

main.lisp (file)


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

Appendix A Indexes


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

A.1 Concepts

Jump to:   A   F   L   M  
Index Entry  Section

A
astonish.asd: The astonish․asd file
astonish/src: The astonish/src module
astonish/src/main.lisp: The astonish/src/main․lisp file

F
File, Lisp, astonish.asd: The astonish․asd file
File, Lisp, astonish/src/main.lisp: The astonish/src/main․lisp file

L
Lisp File, astonish.asd: The astonish․asd file
Lisp File, astonish/src/main.lisp: The astonish/src/main․lisp file

M
Module, astonish/src: The astonish/src module

Jump to:   A   F   L   M  

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

A.2 Functions

Jump to:   C   F   L   M   S  
Index Entry  Section

C
cons-difference: Internal functions

F
filter-conses-by-car: Internal functions
Function, cons-difference: Internal functions
Function, filter-conses-by-car: Internal functions
Function, lisp-file: Internal functions
Function, load-forms-from-file: Exported functions
Function, macroexpand-select: Exported functions
Function, map-inodes: Internal functions
Function, select-conses: Exported functions

L
lisp-file: Internal functions
load-forms-from-file: Exported functions

M
macroexpand-select: Exported functions
map-inodes: Internal functions

S
select-conses: Exported functions

Jump to:   C   F   L   M   S  

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

A.3 Variables


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

A.4 Data types

Jump to:   A   P   S  
Index Entry  Section

A
astonish: The astonish system
astonish: The astonish package

P
Package, astonish: The astonish package

S
System, astonish: The astonish system

Jump to:   A   P   S