The meta-sexp Reference Manual

Table of Contents

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

The meta-sexp Reference Manual

This is the meta-sexp Reference Manual, generated automatically by Declt version 2.4 "Will Decker" on Wed Jun 20 12:16:02 2018 GMT+0.


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

1 Introduction

 ,----------.
 | OVERVIEW |
 `----------'

meta-sexp is a META parser generator using LL(1) grammars with
s-expressions. meta-sexp uses in-memory string vectors, instead of
commonly used streams, for efficiently stepping backward and forward
through the input. It is tested on SBCL but should be portable to
other implementations as well.

meta-sexp is implemented using sevaral transformation methods.
Therefore, besides builtin grammar transformators coming with
meta-sexp by default, you are allowed to add your own transformation
methods too.

Inspired by src/parser.lisp of core-stream project at
http://core.gen.tr/

Idea is based on the META language discussed in `Pragmatic Parsing
in Common Lisp' paper of Henry G. Baker
[ACM Lisp Pointers 4, 2 (Apr/Jun 1991), 3-15]


 ,--------------------.
 | QUICK INTRODUCTION |
 `--------------------'

In most of the time, you'll need to define your own parsers using
CREATE-PARSER-CONTEXT methods and DEFRULE, DEFRENDERER macros.

  create-parser-context ((input string) &key start end attachment)
  create-parser-context ((input string-stream) &key buffer-size start end attachment)

  defrule (name (&rest args) (&optional attachment) &body body)
  defrenderer (name (&rest args) (&optional attachment) &body body)

In a rule or renderer body, if supplied, ATTACHMENT argument will get
bound to ATTACHMENT keyword given to CREATE-PARSER-CONTEXT.

In some certain situations, you may also need to use DEFATOM too. See
atoms.lisp for DEFATOM examples.

Here is a tiny example:

  (defrule integer? (&aux (sign 1) d (num 0)) ()
    (:? (:or (:and "-" (:assign sign -1))
             "+"))
    (:+ (:assign d (:type digit?))
        (:assign num (+ (* num 10)
	                (- (char-code d) #.(char-code #\0)))))
    (:return (* sign num)))

  (integer? (create-parser-context "+123")) ==> 123
  (integer? (create-parser-context "-123")) ==> -123

Here is another example demonstrating the usage of META symbol.

  (defrule in-wonderland? () ()
    "META-SEXP"
    (progn
      (format t "META-SEXP in Wonderland!")
      (meta (:type space?)
	    "in Wonderland!"))
    (:return t))

  (in-wonderland?
   (create-parser-context "META-SEXP in Wonderland!"))
  META-SEXP in Wonderland!
  ==> T

  (in-wonderland?
   (create-parser-context "META-SEXP in Fooland!"))
  META-SEXP in Wonderland!
  ==> NIL

Here's a complete example with renderers and attachments.

  (defrenderer internal-link! (label &optional text) (attachment)
    (format attachment "~a"
            label (if (empty-char-accum-p text) label text)))
  
  (defrule internal-link? (&aux (ref (make-char-accum)) (text (make-char-accum))) ()
    "[["
    (:+ (:not (:or "]]" (:type (or white-space? newline?))))
        (:char-push ref))
    (:? (:* (:type (or white-space? newline?)))
        (:+ (:not "]]")
	    (:char-push text)))
    "]]"
    (:render internal-link! ref text))
  
  (defrule wiki-markup? (&aux c) (attachment)
    (:* (:or (:rule internal-link?)
             (:and (:assign c (:read-atom))
	           (write-char c attachment))))
    (get-output-stream-string attachment))

  (wiki-markup?
   (create-parser-context
    "foo bar [[ref text]] and [[just-ref]] here."
    :attachment (make-string-output-stream)))
  ==> "foo bar text and just-ref here."

What's the role of ATTACHMENT slot given to CREATE-PARSER-CONTEXT (or
specified as a keyword while making an instance of PARSER-CONTEXT
class)? Think it as a state storage unit between passes to defined
rules and renderers. (For instance, in our above example, ATTACHMENT
used as a common output stream.) Yes, it is possible to let this
problem get solved by the programmer via global variables. But this
approach yields to another problem: thread safety. Anyway, that was
the best that I can come up with; if you have any other ideas, I'd be
happy to hear them.


 ,-------------------------.
 | AVAILABLE TYPE CHECKERS |
 `-------------------------'

These functions (and types) are routines introduced using DEFATOM
and operates on character codes. In case of need, you can add your
own type checkers. (See source for examples.)

ALNUM? ALPHA? GRAPHIC? ASCII? BIT? DIGIT? EXTENDED? LOWER? NEWLINE?
SPACE? TAB? UPPER? WHITE-SPACE?


 ,--------------------------.
 | BUILT-IN TRANSFORMATIONS |
 `--------------------------'

(:ICASE FORM FORM ...)
  Make case-insensitive atom comparison in supplied FORMs.

(:CHECKPOINT FORM)
  Sequentially evaluates supplied forms and if any of them fails,
  moves cursor back to its start position :CHECKPOINT began.

(:AND FORM FORM ...)
(:OR FORM FORM ...)

(:NOT FORM)
  Identical to (NOT FORM). (FORM is encapsulated within a :CHECKPOINT
  before getting evaluated.)

(:RETURN VALUE VALUE ...)
  Returns from the rule with supplied VALUEs.

(:RENDER RENDERER ARG ARG ...)
  Calls specified RENDERER (that is defined with DEFRENDERER) with
  supplied arguments.

(:? FORM FORM ...)
  Sequentially evaluates supplied FORMs within an AND scope and
  regardless of the return value of ANDed FORMs, block returns T.
  (Similar to `?' in regular expressions.)

(:* FORM FORM ...)
  Sequentially evaluates supplied FORMs within an AND scope until it
  returns NIL. Regardless of the return value of ANDed FORMs, block
  returns T. (Similar to `*' in regular expressions.)

(:+ FORM FORM ...)
  Sequentially evaluates supplied FORMs within an AND scope, and
  repeats this process till FORMs return NIL. Scope returns T if FORMs
  returned T once or more, otherwise returns NIL. (Similar to `{1,}'
  in regular expressions.)

(:TYPE TYPE-CHECKER)
(:TYPE (OR TYPE-CHECKER TYPE-CHECKER ...))
  Checks type of the atom at the current position through supplied
  function(s).

(:RULE RULE ARG ARG ...)
(:RULE (OR RULE RULE ...) ARG ARG ...)
  Tests input in the current cursor position using specified
  type/form. If any, supplied arguments will get passed to rule.

(:ASSIGN VAR FORM)
(:ASSIGN (VAR1 VAR2 ...) FORM)
  Assigns returned value of FORM to VAR, and returns assigned
  value. (Latter form works similar to MULTIPLE-VALUE-SETQ.)

(:LIST-PUSH ITEM-VAR LIST-ACCUM)
(:CHAR-PUSH CHAR-VAR CHAR-ACCUM)
(:CHAR-PUSH CHAR-ACCUM)
  Pushes supplied ITEM-VAR/CHAR-VAR into specified
  LIST-ACCUM/CHAR-ACCUM. If :CHAR-PUSH is called with only one
  argument, current character gets read and pushed into supplied
  accumulator. (You can use MAKE-LIST-ACCUM and MAKE-CHAR-ACCUM
  functions to initialize new accumulators. Moreover, you'll probably
  need EMPTY-LIST-ACCUM-P and EMPTY-CHAR-ACCUM-P predicates too.)

(:LIST-RESET LIST-ACCUM)
(:CHAR-RESET CHAR-ACCUM)
  Resets supplied accumulators.

(:EOF)
  Returns true when reached to the end of supplied input data.

(:READ-ATOM)
  Reads current atom at the cursor position and returns read atom.

(:DEBUG)
(:DEBUG VAR)
  Prints current character and its position in the input data. If VAR
  is specified, prints the value of the VAR.

If a form doesn't start with any of the above keywords, there're
three possiblities remaining:

  i. This can be a character.
 ii. This can be a string. (Will get expanded into an AND'ed character
     list with an outermost :CHECKPOINT.)
iii. Treat as a custom form. (Will get evaluated as is)

When you're in the third situation, to be able to get your META
s-expressions compiled again, use META keyword. (See the second
example in the Quick Introduction.)


 ,---------------------------------.
 | INTRODUCING NEW TRANSFORMATIONS |
 `---------------------------------'

Every transformation process issued by meta-sexp is controlled by
TRANSFORM-GRAMMAR methods.

  (defgeneric transform-grammar (ctx in-meta directive &optional args)
    (:documentation "META grammar transformation methods."))

To introduce a new transformation directive, just create a new
TRANSFORM-GRAMMAR method with related lambda list specializers. For
instance, consider how :AND and :NOT directive transformations are
implemented:

  (defmethod transform-grammar
      (ctx (in-meta (eql t)) (directive (eql :and)) &optional args)
    `(and ,@(mapcar #'(lambda (form) (transform-grammar ctx t form))
                    args)))
  
  (defmethod transform-grammar
      (ctx (in-meta (eql t)) (directive (eql :not)) &optional args)
    (transform-grammar
     ctx t :checkpoint
     `((not ,(transform-grammar ctx t (car args))))))

Also pay attention how meta-sexp handles unrecognized transformation
directives:

  (defmethod transform-grammar (ctx in-meta directive &optional args)
    "The most unspecific transformation method."
    (declare (ignore args))
    (cond
      ((and in-meta (consp directive) (keywordp (car directive)))
       (transform-grammar ctx t (car directive) (cdr directive)))
      ((and (not in-meta) (consp directive) (eql 'meta (car directive)))
       (transform-grammar ctx t :and (cdr directive)))
      ((consp directive)
       (mapcar #'(lambda (form) (transform-grammar ctx nil form))
                         directive))
      (t directive)))
     
With similar patterns, you can introduce new transformation directives
to meta-sexp.

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 meta-sexp

Source

meta-sexp.asd (file)

Components

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

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 files   [Contents][Index]

3.1.1 meta-sexp.asd

Location

meta-sexp.asd

Systems

meta-sexp (system)

Packages

meta-sexp-asd

Exported Definitions

+meta-sexp-version+ (constant)


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

3.1.2 meta-sexp/packages.lisp

Parent

meta-sexp (system)

Location

packages.lisp

Packages

meta-sexp


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

3.1.3 meta-sexp/util.lisp

Dependency

packages.lisp (file)

Parent

meta-sexp (system)

Location

util.lisp

Exported Definitions
Internal Definitions

with-unique-names (macro)


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

3.1.4 meta-sexp/meta-sexp.lisp

Dependency

util.lisp (file)

Parent

meta-sexp (system)

Location

meta-sexp.lisp

Exported Definitions
Internal Definitions

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

3.1.5 meta-sexp/atoms.lisp

Dependency

meta-sexp.lisp (file)

Parent

meta-sexp (system)

Location

atoms.lisp

Exported Definitions

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

4 Packages

Packages are listed by definition order.


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

4.1 meta-sexp-asd

Source

meta-sexp.asd

Use List
Exported Definitions

+meta-sexp-version+ (constant)


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

4.2 meta-sexp

LL(1) parser generator in META using s-expressions.

Source

packages.lisp (file)

Use List

common-lisp

Exported Definitions
Internal Definitions

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

5 Definitions

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


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

5.1 Exported definitions


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

5.1.1 Constants

Constant: +meta-sexp-version+
Package

meta-sexp-asd

Source

meta-sexp.asd


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

5.1.2 Macros

Macro: defatom NAME (C) &body BODY
Package

meta-sexp

Source

meta-sexp.lisp (file)

Macro: defrenderer NAME (&rest ARGS) (&optional ATTACHMENT) &body BODY
Package

meta-sexp

Source

meta-sexp.lisp (file)

Macro: defrule NAME (&rest ARGS) (&optional ATTACHMENT) &body BODY
Package

meta-sexp

Source

meta-sexp.lisp (file)

Macro: list-accum-push ITEM ACCUM
Package

meta-sexp

Source

util.lisp (file)

Macro: reset-list-accum ACCUM
Package

meta-sexp

Source

util.lisp (file)


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

5.1.3 Functions

Function: alnum? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: alpha? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: ascii? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: bit? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: char-accum-push CHAR ACCUM
Package

meta-sexp

Source

util.lisp (file)

Function: digit? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: empty-char-accum-p ACCUM
Package

meta-sexp

Source

util.lisp (file)

Function: empty-list-accum-p ACCUM
Package

meta-sexp

Source

util.lisp (file)

Function: extended? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: graphic? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: lower? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: make-char-accum &key SIZE
Package

meta-sexp

Source

util.lisp (file)

Function: make-list-accum ()
Package

meta-sexp

Source

util.lisp (file)

Function: newline? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: reset-char-accum ACCUM
Package

meta-sexp

Source

util.lisp (file)

Function: space? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: tab? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: upper? C
Package

meta-sexp

Source

atoms.lisp (file)

Function: white-space? C
Package

meta-sexp

Source

atoms.lisp (file)


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

5.1.4 Generic functions

Generic Function: create-parser-context INPUT &rest ARGS &key BUFFER-SIZE START END ATTACHMENT
Package

meta-sexp

Source

meta-sexp.lisp (file)

Methods
Method: create-parser-context (INPUT string-stream) &key BUFFER-SIZE START END ATTACHMENT
Method: create-parser-context (INPUT string) &key START END ATTACHMENT
Generic Function: transform-grammar RET CTX IN-META DIRECTIVE &optional ARGS

META grammar transformation methods.

Package

meta-sexp

Source

meta-sexp.lisp (file)

Methods
Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql debug)) &optional ARGS

(:DEBUG)
(:DEBUG VAR)

Print current character and its position in the input data. If VAR is specified, print the value of the VAR.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql read-atom)) &optional ARGS

(:READ-ATOM)

Reads current atom at the cursor position and returns read atom.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql eof)) &optional ARGS

(:EOF)

Returns T when reached to the end of supplied input data.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql char-reset)) &optional ARGS

(:CHAR-RESET CHAR-ACCUM)

Resets supplied CHAR-ACCUM.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql char-push)) &optional ARGS

(:CHAR-PUSH CHAR-VAR CHAR-ACCUM)
(:CHAR-PUSH CHAR-ACCUM)

Pushes supplied CHAR-VAR into specified CHAR-ACCUM. If called with a single argument, current character gets read and pushed into supplied accumulator. (See MAKE-CHAR-ACCUM and EMPTY-CHAR-ACCUM-P.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql list-reset)) &optional ARGS

(:LIST-RESET LIST-ACCUM)

Resets supplied LIST-ACCUM.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql list-push)) &optional ARGS

(:LIST-PUSH ITEM-VAR LIST-ACCUM)

Pushes ITEM-VAR into the specified LIST-ACCUM. (See MAKE-LIST-ACCUM and EMPTY-LIST-ACCUM-P.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql assign)) &optional ARGS

(:ASSIGN VAR FORM)
(:ASSIGN (VAR1 VAR2 ...) FORM)

Assigns returned value of FORM to VAR, and returns assigned value. (Latter form works similar to MULTIPLE-VALUE-SETQ.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql rule)) &optional ARGS

(:RULE RULE ARG ARG ...)
(:RULE (OR RULE RULE ...) ARG ARG ...)

Tests input in the current cursor position using specified type/form. If any, supplied arguments will get passed to rule.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql type)) &optional ARGS

(:TYPE TYPE-CHECKER)
(:TYPE (OR TYPE-CHECKER TYPE-CHECKER ...))

Checks type of the atom at the current position through supplied function(s).

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql +)) &optional ARGS

(:+ FORM FORM ...)

Sequentially evaluates supplied FORMs within an AND scope, and repeats this process till FORMs return NIL. Scope returns T if FORMs returned T once or more, otherwise returns NIL. (Similar to ‘{1,}’ in regular expressions.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql *)) &optional ARGS

(:* FORM FORM ...)

Sequentially evaluates supplied FORMs within an AND scope until it returns NIL. Regardless of the return value of ANDed FORMs, block returns T. (Similar to ‘*’ in regular expressions.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql ?)) &optional ARGS

(:? FORM FORM ...)

Sequentially evaluates supplied FORMs within an AND scope and regardless of the return value of ANDed FORMs, block returns T. (Similar to ‘?’ in regular expressions.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql render)) &optional ARGS

(:RENDER RENDERER ARG ARG ...)

Calls specified renderer (which is defined with DEFRENDERER) with the supplied arguments.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql return)) &optional ARGS

(:RETURN VALUE VALUE ...)

Returns from the rule with supplied VALUEs.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql not)) &optional ARGS

(:NOT FORM)

Identical to (NOT FORM). (FORM is encapsulated within a :CHECKPOINT before getting evaluated.)

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql or)) &optional ARGS

(:OR FORM FORM ...)

Sequentially evalutes FORMs identical to OR.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql and)) &optional ARGS

(:AND FORM FORM ...)

Sequentially evaluates FORMs identical to AND.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql checkpoint)) &optional ARGS

(:CHECKPOINT FORM FORM ...)

Sequentially evaluates supplied forms and if any of them fails, moves cursor back to its start position :CHECKPOINT began.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE (eql icase)) &optional ARGS

(:ICASE FORM FORM ...)

Make case-insensitive atom comparison in supplied FORMs.

Method: transform-grammar RET CTX IN-META DIRECTIVE &optional ARGS

The most unspecific transformation method.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE string) &optional ARGS

Transforms a string form.

Method: transform-grammar RET CTX (IN-META (eql t)) (DIRECTIVE character) &optional ARGS

Transforms a character form.


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

5.1.5 Types

Type: alnum? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: alpha? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: ascii? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: bit? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: digit? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: extended? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: graphic? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: lower? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: newline? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: space? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: tab? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: upper? ()
Package

meta-sexp

Source

atoms.lisp (file)

Type: white-space? ()
Package

meta-sexp

Source

atoms.lisp (file)


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

5.2 Internal definitions


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

5.2.1 Macros

Macro: match-rule CTX RULE ARGS
Package

meta-sexp

Source

meta-sexp.lisp (file)

Macro: match-type CTX TYPE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Macro: with-unique-names (&rest BINDINGS) &body BODY

Syntax: WITH-UNIQUE-NAMES ( { var | (var x) }* ) declaration* form*

Executes a series of forms with each VAR bound to a fresh, uninterned symbol. The uninterned symbol is as if returned by a call to GENSYM with the string denoted by X - or, if X is not supplied, the string denoted by VAR - as argument.

The variable bindings created are lexical unless special declarations are specified. The scopes of the name bindings and declarations do not include the Xs.

The forms are evaluated in order, and the values of all but the last are discarded (that is, the body is an implicit PROGN).

Package

meta-sexp

Source

util.lisp (file)


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

5.2.2 Functions

Function: checkpoint CTX
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: commit CTX
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: copy-parser-context INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: make-parser-context &key (DATA DATA) (SIZE SIZE) (CURSOR CURSOR) (CHECKPOINTS CHECKPOINTS) (ICASES ICASES) (ATTACHMENT ATTACHMENT)
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: match-atom CTX ATOM &aux C
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-attachment INSTANCE
Function: (setf parser-context-attachment) VALUE INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-checkpoints INSTANCE
Function: (setf parser-context-checkpoints) VALUE INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-cursor INSTANCE
Function: (setf parser-context-cursor) VALUE INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-data INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-icases INSTANCE
Function: (setf parser-context-icases) VALUE INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-p OBJECT
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: parser-context-size INSTANCE
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: peek-atom CTX
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: read-atom CTX
Package

meta-sexp

Source

meta-sexp.lisp (file)

Function: rollback CTX
Package

meta-sexp

Source

meta-sexp.lisp (file)


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

5.2.3 Structures

Structure: parser-context ()
Package

meta-sexp

Source

meta-sexp.lisp (file)

Direct superclasses

structure-object (structure)

Direct slots
Slot: data
Type

string

Readers

parser-context-data (function)

Writers

(setf parser-context-data) (function)

Slot: size
Type

unsigned-byte

Readers

parser-context-size (function)

Writers

(setf parser-context-size) (function)

Slot: cursor
Type

unsigned-byte

Initform

0

Readers

parser-context-cursor (function)

Writers

(setf parser-context-cursor) (function)

Slot: checkpoints
Readers

parser-context-checkpoints (function)

Writers

(setf parser-context-checkpoints) (function)

Slot: icases
Readers

parser-context-icases (function)

Writers

(setf parser-context-icases) (function)

Slot: attachment
Readers

parser-context-attachment (function)

Writers

(setf parser-context-attachment) (function)


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

Appendix A Indexes


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

A.1 Concepts

Jump to:   F   L   M  
Index Entry  Section

F
File, Lisp, meta-sexp.asd: The meta-sexp<dot>asd file
File, Lisp, meta-sexp/atoms.lisp: The meta-sexp/atoms<dot>lisp file
File, Lisp, meta-sexp/meta-sexp.lisp: The meta-sexp/meta-sexp<dot>lisp file
File, Lisp, meta-sexp/packages.lisp: The meta-sexp/packages<dot>lisp file
File, Lisp, meta-sexp/util.lisp: The meta-sexp/util<dot>lisp file

L
Lisp File, meta-sexp.asd: The meta-sexp<dot>asd file
Lisp File, meta-sexp/atoms.lisp: The meta-sexp/atoms<dot>lisp file
Lisp File, meta-sexp/meta-sexp.lisp: The meta-sexp/meta-sexp<dot>lisp file
Lisp File, meta-sexp/packages.lisp: The meta-sexp/packages<dot>lisp file
Lisp File, meta-sexp/util.lisp: The meta-sexp/util<dot>lisp file

M
meta-sexp.asd: The meta-sexp<dot>asd file
meta-sexp/atoms.lisp: The meta-sexp/atoms<dot>lisp file
meta-sexp/meta-sexp.lisp: The meta-sexp/meta-sexp<dot>lisp file
meta-sexp/packages.lisp: The meta-sexp/packages<dot>lisp file
meta-sexp/util.lisp: The meta-sexp/util<dot>lisp file

Jump to:   F   L   M  

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

A.2 Functions

Jump to:   (  
A   B   C   D   E   F   G   L   M   N   P   R   S   T   U   W  
Index Entry  Section

(
(setf parser-context-attachment): Internal functions
(setf parser-context-checkpoints): Internal functions
(setf parser-context-cursor): Internal functions
(setf parser-context-icases): Internal functions

A
alnum?: Exported functions
alpha?: Exported functions
ascii?: Exported functions

B
bit?: Exported functions

C
char-accum-push: Exported functions
checkpoint: Internal functions
commit: Internal functions
copy-parser-context: Internal functions
create-parser-context: Exported generic functions
create-parser-context: Exported generic functions
create-parser-context: Exported generic functions

D
defatom: Exported macros
defrenderer: Exported macros
defrule: Exported macros
digit?: Exported functions

E
empty-char-accum-p: Exported functions
empty-list-accum-p: Exported functions
extended?: Exported functions

F
Function, (setf parser-context-attachment): Internal functions
Function, (setf parser-context-checkpoints): Internal functions
Function, (setf parser-context-cursor): Internal functions
Function, (setf parser-context-icases): Internal functions
Function, alnum?: Exported functions
Function, alpha?: Exported functions
Function, ascii?: Exported functions
Function, bit?: Exported functions
Function, char-accum-push: Exported functions
Function, checkpoint: Internal functions
Function, commit: Internal functions
Function, copy-parser-context: Internal functions
Function, digit?: Exported functions
Function, empty-char-accum-p: Exported functions
Function, empty-list-accum-p: Exported functions
Function, extended?: Exported functions
Function, graphic?: Exported functions
Function, lower?: Exported functions
Function, make-char-accum: Exported functions
Function, make-list-accum: Exported functions
Function, make-parser-context: Internal functions
Function, match-atom: Internal functions
Function, newline?: Exported functions
Function, parser-context-attachment: Internal functions
Function, parser-context-checkpoints: Internal functions
Function, parser-context-cursor: Internal functions
Function, parser-context-data: Internal functions
Function, parser-context-icases: Internal functions
Function, parser-context-p: Internal functions
Function, parser-context-size: Internal functions
Function, peek-atom: Internal functions
Function, read-atom: Internal functions
Function, reset-char-accum: Exported functions
Function, rollback: Internal functions
Function, space?: Exported functions
Function, tab?: Exported functions
Function, upper?: Exported functions
Function, white-space?: Exported functions

G
Generic Function, create-parser-context: Exported generic functions
Generic Function, transform-grammar: Exported generic functions
graphic?: Exported functions

L
list-accum-push: Exported macros
lower?: Exported functions

M
Macro, defatom: Exported macros
Macro, defrenderer: Exported macros
Macro, defrule: Exported macros
Macro, list-accum-push: Exported macros
Macro, match-rule: Internal macros
Macro, match-type: Internal macros
Macro, reset-list-accum: Exported macros
Macro, with-unique-names: Internal macros
make-char-accum: Exported functions
make-list-accum: Exported functions
make-parser-context: Internal functions
match-atom: Internal functions
match-rule: Internal macros
match-type: Internal macros
Method, create-parser-context: Exported generic functions
Method, create-parser-context: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions
Method, transform-grammar: Exported generic functions

N
newline?: Exported functions

P
parser-context-attachment: Internal functions
parser-context-checkpoints: Internal functions
parser-context-cursor: Internal functions
parser-context-data: Internal functions
parser-context-icases: Internal functions
parser-context-p: Internal functions
parser-context-size: Internal functions
peek-atom: Internal functions

R
read-atom: Internal functions
reset-char-accum: Exported functions
reset-list-accum: Exported macros
rollback: Internal functions

S
space?: Exported functions

T
tab?: Exported functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions
transform-grammar: Exported generic functions

U
upper?: Exported functions

W
white-space?: Exported functions
with-unique-names: Internal macros

Jump to:   (  
A   B   C   D   E   F   G   L   M   N   P   R   S   T   U   W  

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

A.3 Variables

Jump to:   +  
A   C   D   I   S  
Index Entry  Section

+
+meta-sexp-version+: Exported constants

A
attachment: Internal structures

C
checkpoints: Internal structures
Constant, +meta-sexp-version+: Exported constants
cursor: Internal structures

D
data: Internal structures

I
icases: Internal structures

S
size: Internal structures
Slot, attachment: Internal structures
Slot, checkpoints: Internal structures
Slot, cursor: Internal structures
Slot, data: Internal structures
Slot, icases: Internal structures
Slot, size: Internal structures

Jump to:   +  
A   C   D   I   S  

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

A.4 Data types

Jump to:   A   B   D   E   G   L   M   N   P   S   T   U   W  
Index Entry  Section

A
alnum?: Exported types
alpha?: Exported types
ascii?: Exported types

B
bit?: Exported types

D
digit?: Exported types

E
extended?: Exported types

G
graphic?: Exported types

L
lower?: Exported types

M
meta-sexp: The meta-sexp system
meta-sexp: The meta-sexp package
meta-sexp-asd: The meta-sexp-asd package

N
newline?: Exported types

P
Package, meta-sexp: The meta-sexp package
Package, meta-sexp-asd: The meta-sexp-asd package
parser-context: Internal structures

S
space?: Exported types
Structure, parser-context: Internal structures
System, meta-sexp: The meta-sexp system

T
tab?: Exported types
Type, alnum?: Exported types
Type, alpha?: Exported types
Type, ascii?: Exported types
Type, bit?: Exported types
Type, digit?: Exported types
Type, extended?: Exported types
Type, graphic?: Exported types
Type, lower?: Exported types
Type, newline?: Exported types
Type, space?: Exported types
Type, tab?: Exported types
Type, upper?: Exported types
Type, white-space?: Exported types

U
upper?: Exported types

W
white-space?: Exported types

Jump to:   A   B   D   E   G   L   M   N   P   S   T   U   W