The with-c-syntax Reference Manual

This is the with-c-syntax Reference Manual, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 08 19:57:16 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

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


2.1 with-c-syntax

with-c-syntax is a fun package which introduces the C language syntax into Common Lisp.

Author

YOKOTA Yuki <>

License

WTFPL

Dependencies
  • alexandria (system).
  • yacc (system).
  • named-readtables (system).
  • cl-ppcre (system).
  • trivial-gray-streams (system).
  • asdf (system).
  • split-sequence (system).
  • float-features (system).
  • floating-point-contractions (system).
Source

with-c-syntax.asd.

Child Components

3 Modules

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


3.1 with-c-syntax/src

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

with-c-syntax (system).

Child Components

3.2 with-c-syntax/libc

Dependency

src (module).

Source

with-c-syntax.asd.

Parent Component

with-c-syntax (system).

Child Components

3.3 with-c-syntax/include

Dependency

libc (module).

Source

with-c-syntax.asd.

Parent Component

with-c-syntax (system).

Child Components

4 Files

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


4.1 Lisp


4.1.1 with-c-syntax/with-c-syntax.asd

Source

with-c-syntax.asd.

Parent Component

with-c-syntax (system).

ASDF Systems

with-c-syntax.


4.1.2 with-c-syntax/package.lisp

Source

with-c-syntax.asd.

Parent Component

with-c-syntax (system).

Packages

with-c-syntax.


4.1.4 with-c-syntax/src/util.lisp

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.5 with-c-syntax/src/condition.lisp

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.9 with-c-syntax/src/reader.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.10 with-c-syntax/src/struct.lisp

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.11 with-c-syntax/src/typedef.lisp

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

*typedef-names* (special variable).


4.1.12 with-c-syntax/src/pseudo-pointer.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.13 with-c-syntax/src/lexer.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Internals

4.1.14 with-c-syntax/src/compiler.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.15 with-c-syntax/src/preprocessor.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

4.1.16 with-c-syntax/src/predefined-macro.lisp

Dependency

preprocessor.lisp (file).

Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface
Internals

+pp-date-month-name+ (constant).


4.1.17 with-c-syntax/src/with-c-syntax.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

src (module).

Public Interface

with-c-syntax (macro).

Internals

expand-c-syntax (function).


4.1.18 with-c-syntax/libc/package.lisp

Source

with-c-syntax.asd.

Parent Component

libc (module).

Packages

4.1.19 with-c-syntax/libc/util.lisp

Dependency

package.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Internals

4.1.20 with-c-syntax/libc/assert.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface

4.1.21 with-c-syntax/libc/ctype.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface

4.1.22 with-c-syntax/libc/errno.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
  • edom (special variable).
  • eilseq (special variable).
  • erange (special variable).
  • errno (special variable).
Internals

4.1.23 with-c-syntax/libc/fenv.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
Internals

4.1.24 with-c-syntax/libc/float.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
Internals

mantissa-radix-change (function).


4.1.25 with-c-syntax/libc/iso646.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).


4.1.26 with-c-syntax/libc/limits.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
Internals

4.1.27 with-c-syntax/libc/math.lisp

Dependencies
Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
Internals

4.1.28 with-c-syntax/libc/stdarg.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface

4.1.29 with-c-syntax/libc/stddef.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface

4.1.30 with-c-syntax/libc/string.lisp

Dependency

util.lisp (file).

Source

with-c-syntax.asd.

Parent Component

libc (module).

Public Interface
Internals

4.2 Static


4.2.1 with-c-syntax/include/iso646.h

Source

with-c-syntax.asd.

Parent Component

include (module).


4.2.2 with-c-syntax/include/stdarg.h

Source

with-c-syntax.asd.

Parent Component

include (module).


4.2.3 with-c-syntax/include/stddef.h

Source

with-c-syntax.asd.

Parent Component

include (module).


5 Packages

Packages are listed by definition order.


5.1 with-c-syntax.preprocessor-directive.upcased

Source

case-aware-find-symbol.lisp.


5.2 with-c-syntax.libc

with-c-syntax libc package.

Source

package.lisp.

Used By List

with-c-syntax.libc-implementation.

Public Interface

5.3 with-c-syntax.syntax

Holds symbols denoting C operators and keywords.

Source

package.lisp.

Used By List

with-c-syntax.core.


5.4 with-c-syntax.preprocess-operator.upcased

Source

case-aware-find-symbol.lisp.


5.5 with-c-syntax.core

with-c-syntax core package.

Source

package.lisp.

Use List
Used By List

with-c-syntax.libc-implementation.

Public Interface
Internals

5.6 with-c-syntax.pragma-name.upcased

Source

case-aware-find-symbol.lisp.


5.7 with-c-syntax.predefined-macro

Source

package.lisp.

Public Interface

5.8 with-c-syntax.pragma-name

Source

package.lisp.


5.9 with-c-syntax

The with-c-syntax package, holding public APIs.

Source

package.lisp.

Used By List

with-c-syntax.core.

Public Interface

5.10 with-c-syntax.syntax.upcased

Source

case-aware-find-symbol.lisp.


5.11 with-c-syntax.libc-implementation

with-c-syntax libc implemetation package.

Source

package.lisp.

Use List
Internals

5.12 with-c-syntax.punctuator

C punctuators. Some symbols are from ‘with-c-syntax.syntax’ package.

Source

package.lisp.


5.13 with-c-syntax.preprocessor-directive

Source

package.lisp.


5.14 with-c-syntax.preprocess-operator

Source

package.lisp.


6 Definitions

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


6.1 Public Interface


6.1.1 Constants

Constant: +bel-character+
Package

with-c-syntax.core.

Source

util.lisp.

Constant: +newline-marker+

Used for saving newline chars from reader to preprocessor.

Package

with-c-syntax.core.

Source

reader.lisp.

Constant: +nul-character+
Package

with-c-syntax.core.

Source

util.lisp.

Constant: +vertical-tab-character+
Package

with-c-syntax.core.

Source

util.lisp.

Constant: +whitespace-marker+

Used for saving whitespace chars from reader to preprocessor, for preprocessor directives.

Package

with-c-syntax.core.

Source

reader.lisp.

Constant: __stdc__
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Constant: __stdc_hosted__
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Constant: __stdc_mb_might_neq_wc__
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Constant: __stdc_version__
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Constant: char_bit
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: char_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: char_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: dbl_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_epsilon
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_mant_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_max
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_max_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_max_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_min
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_min_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: dbl_min_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: decimal_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: fe_all_except
Package

with-c-syntax.libc.

Source

fenv.lisp.

Constant: fe_divbyzero
Package

with-c-syntax.libc.

Source

fenv.lisp.

Constant: fe_invalid
Package

with-c-syntax.libc.

Source

fenv.lisp.

Constant: fe_overflow
Package

with-c-syntax.libc.

Source

fenv.lisp.

Constant: fe_underflow
Package

with-c-syntax.libc.

Source

fenv.lisp.

Constant: flt_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_epsilon
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_eval_method
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_mant_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_max
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_max_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_max_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_min
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_min_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_min_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_radix
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: flt_rounds
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: fp_ilogb0
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_ilogbnan

with-c-syntax definition FP_ILOGBNAN

Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_infinite
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_nan
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_normal
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_subnormal
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: fp_zero
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: huge_val
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: huge_valf
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: huge_vall
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: infinity
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: int_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: int_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: ldbl_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_epsilon
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_mant_dig
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_max
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_max_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_max_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_min
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_min_10_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: ldbl_min_exp
Package

with-c-syntax.libc.

Source

float.lisp.

Constant: llong_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: llong_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: long_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: long_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: math_errexcept
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: math_errhandling
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: math_errno
Package

with-c-syntax.libc.

Source

math.lisp.

Constant: mb_len_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: null

Holding ‘CL:NIL’ for acting NULL of C language.

Package

with-c-syntax.libc.

Source

stddef.lisp.

Constant: schar_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: schar_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: shrt_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: shrt_min
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: uchar_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: uint_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: ullong_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: ulong_max
Package

with-c-syntax.libc.

Source

limits.lisp.

Constant: ushrt_max
Package

with-c-syntax.libc.

Source

limits.lisp.


6.1.2 Special variables

Special Variable: *previous-readtable*

Holds the readtable used by #‘ syntax.
This is bound by ’#{’ read macro to the ‘*readtable*’ at that time.

Package

with-c-syntax.

Source

reader.lisp.

Special Variable: *with-c-syntax-find-include-file-function-list*

List of functions used for searching include files with ’#include <...>’ style. Each function should take one argument and returns a pathname, or nil if failed. See ‘find-include-<header>-file’.

Package

with-c-syntax.

Source

preprocessor.lisp.

Special Variable: *with-c-syntax-reader-case*

Holds the readtable case used by ’#{’ reader function.

When this is not nil, it must be one of ‘:upcase’, ‘:downcase’, ‘:preserve’, or ‘:invert’. The specified case is used as the readtable-case inside ’#{’ and ’}#’ and passed to the
wrapping ‘with-c-syntax’ form.

When this is nil, the ‘readtable-case’ of the current ‘*readtable*’ at ’#{’ is used.

Package

with-c-syntax.

Source

reader.lisp.

Special Variable: *with-c-syntax-reader-level*

Holds the reader level used by ’#{’ reader function.
The value is one of 0, 1 (default), 2.

For inside ’#{’ and ’}#’, three syntaxes are defined. These syntaxes are selected by the infix parameter of the ’#{’ dispatching macro character. If it not specified, the value of this variable is used.

Available syntaxes are below:

* Level 0 (conservative)

In level 0, these reader macros are installed.

- ’,’ :: ’,’ is read as a symbol. (In ANSI CL, a comma is defined as
an invalid char outside the backquote syntax.)
- ’:’ :: Reads a solely ’:’ as a symbol. Not a solely one (like ‘cl:cons’) works as a normal package marker.

Level 0 is almost compatible with the standard syntax. However, we need many escapes for using C operators.

* Level 1 (aggressive).

In level 1, these reader macros are installed.

- ’0’ :: If followed by ’x’ or ’X’, hexadecimal integer (like ’0xdeadbeef’) and hexadecimal floating number (like ’0x1.ffp1’) syntax are enabled. Otherwise, it is treated as a normal token of Common Lisp.
- ’|’ :: If ’||’ appeared, it becomes a symbol. The ’empty symbol’ syntax is lost. If ’|’ appeared followed by a terminating char, it becomes a single character symbol. Because ’|’ becomes a macro character, it cannot be used for a multiple escape inside a symbol notation. (e.g. Use ’|A B C|’ instead of ’a| |b| |c’).
- ’{’, ’}’, ’[’, ’]’ :: These become a terminating character, and read as a symbol.
- ’‘’ :: ’‘’ reads a next s-exp in ‘*previous-readtable*’ readtable. This works as an escape from ’#{’ and ’}#’. The ’backquote’ functionality is lost.
- ’.’ :: Reads a solely ’.’ as a symbol. The ’consing dot’ functionality is lost.
- ’/’ :: ’//’ means a line comment, ’/* ... */’ means a block
comment. ’/’ is still non-terminating and it has special meanings only if followed by ’/’ or ’*’. (Ex: ’a/b/c’ or ’/+aaa+/’ are still valid symbols.)
- ’"’ :: The double-quote works as a string literal of C. Especially, escaping is treated as C. The original functionality is lost.
- ’;’ :: ’;’ becomes a terminating character, and read as a
symbol. The ’comment’ functionality is lost.
- ’(’ and ’)’ :: parenthesis become a terminating character, and read as a symbol. The ’reading a list’ functionality is lost.

Level 1 still mostly keeps the syntax of symbols, since many constituent characters are left unchanged. But some major macro characters are overwritten. Especially, ’(’ and ’)’ loses its functionalities. For constructing a list of Lisp, the ’‘’ syntax must be used.

* Level 2 (overkill)

In this level, these characters become terminating, and read as a symbol listed below.

- ’?’ :: ’?’
- ’~’ :: ’~’
- ’:’ :: ’:’ or a (digraph ’:>’)
- ’=’ :: ’=’ or ’==’
- ’*’ :: ’*’ or ’*=’
- ’^’ :: ’^’ or ’^=’
- ’!’ :: ’!’ or ’!=’
- ’&’ :: ’&’, ’&&’, or ’&=’
- ’|’ :: ’|’, ’||’, or ’|=’
- ’+’ :: ’+’, ’++’, or ’+=’
- ’-’ :: ’-’, ’–’, ’-=’, or ’->’
- ’>’ :: ’>’, ’>>’, ’>=’, or ’>>=’
- ’<’ :: ’<’, ’<<’, ’<=’, ’<<=’, or digraphs (’<:’, ’<%’)
- ’/’ :: ’/’, or ’/=’. ’//’ means a line comment, and ’/* ... */’
means a block comment.
- ’.’ :: ’.’, ’...’, or a numeric literal of C language.
- ’%’ :: ’%’, ’%=’, or digraphs (’%>’, ’%:’, ’%:%:’)

And, these characters are changed:

- Digit characters (0,1,2,3,4,5,6,7,8,9) are read as a C numeric literals.
- The single-quote (’) works as a character literal of C. The ‘quote’ functionality is lost. (This prevents the Lisp syntax extremely, so enabled only in level 2).

In this level, there is no compatibilities between symbols of Common Lisp. Especially, for denoting a symbol consists of terminating characters, escapes are required. (ex. most-positive-fixnum)

Package

with-c-syntax.

Source

reader.lisp.

Special Variable: edom
Package

with-c-syntax.libc.

Source

errno.lisp.

Special Variable: eilseq
Package

with-c-syntax.libc.

Source

errno.lisp.

Special Variable: erange
Package

with-c-syntax.libc.

Source

errno.lisp.

Special Variable: errno

A symbol denoting ’errno’ of C, or NIL.
If a function of ‘with-c-syntax.libc’ caught error, it will set the error to this.

Package

with-c-syntax.libc.

Source

errno.lisp.

Special Variable: nan
Package

with-c-syntax.libc.

Source

math.lisp.

Special Variable: ndebug

This variable is seen by |assert|. Please refer |assert|’s docstring.

Package

with-c-syntax.libc.

Source

assert.lisp.


6.1.3 Macros

Macro: assert (&rest args)

This emulates ’assert’ of the C language.
If ‘NDEBUG’ is bound and its value is true, ‘|assert|’ will be
expanded to a no-op. If not (‘NDEBUG’ is unbound or bound to NIL), ‘|assert|’ will be expanded to ‘cl:assert’.

This macro sees ‘NDEBUG’ value only when macroexpanding-time, not in runtime. (If you want to change ‘NDEBUG’ locally, you should use ‘compiler-let’.)

Package

with-c-syntax.libc.

Source

assert.lisp.

Macro: get-variadic-arguments (&optional last-argument-name)

It returns the variadic arguments of a function defined by with-c-syntax. If this is called outside of a variadic function, an error is signaled. When defining a variadic function, a local macro has same name is established.

This is not intended for calling directly. The va_start macro uses this.

Package

with-c-syntax.core.

Source

compiler.lisp.

Macro: va_copy (dest src)
Package

with-c-syntax.libc.

Source

stdarg.lisp.

Macro: va_end (ap)
Package

with-c-syntax.libc.

Source

stdarg.lisp.

Macro: va_start (ap last)
Package

with-c-syntax.libc.

Source

stdarg.lisp.

Macro: with-c-syntax ((&rest options &key preprocess reader-level readtable-case input-file-pathname try-add-{}) &body body)

This macro is a entry point of the with-c-syntax system. BODY will be interpreted as C syntax, executed, and return values.

This macro returns the last form’s value if BODY is a compound
statement, or returns NIL if BODY is a compilation unit.

PREPROCESS specifies how to do preprocess. If nil, this macro compiles BODY without preprocessing. If t, preprocesses and compiles BODY. If ‘:preprocess-only’, this macro preprocesses BODY and returns the
result as-is.

READER-LEVEL specifies the reader level (see ‘*with-c-syntax-reader-level*’). This is used when ’#include’ or ’_Pragma()’ was used.

READTABLE-CASE specifies the readtable case of symbols in BODY when it was read. This affects how to intern C keywords by the preprocessor.

INPUT-FILE-PATHNAME is passed to the preprocessor and used when ’__FILE__’ macro was used.

If TRY-ADD-{} is t and an error occurred at parsing, ‘with-c-syntax’
adds ’{’ and ’}’ into the head and tail of FORM respectively, and
tries to parse again.

Package

with-c-syntax.

Source

with-c-syntax.lisp.

Macro: with-pseudo-pointer-scope (() &body body)

In this macro, BODY is executed in a new environment for pseudo-pointers.
A pointer made inside this macro is invalidated outside of this.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.


6.1.4 Compiler macros

Compiler Macro: isunordered (x y)
Package

with-c-syntax.libc.

Source

math.lisp.


6.1.5 Ordinary functions

Function: __date__ (&optional state)
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Function: __file__ (state)
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Function: __line__ (state)
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Function: __time__ (&optional state)
Package

with-c-syntax.predefined-macro.

Source

predefined-macro.lisp.

Function: acos (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: acosh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: add-struct-spec (name sspec)

* Syntax
~add-struct-spec~ name sspec => struct-spec

* Arguments and Values
- name :: a symbol.
- sspec :: a struct-spec instance.
- struct-spec :: a struct-spec instance.

* Description
Establishes a new struct-spec definition named ~name~.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: add-typedef (name spec)

* Syntax
~add-typedef~ name spec => decl-spec

* Arguments and Values
- name :: a symbol
- spec :: a decl-specs instance, or a type specifier. - decl-spec :: a decl-specs instance.

* Description
Establishes a new typedef definition named ~name~.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

typedef.lisp.

Function: asin (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: asinh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: atan (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: atan2 (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: atanh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: c-whitespace-p (char)
Package

with-c-syntax.core.

Source

util.lisp.

Function: cbrt (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: ceil (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: copysign (abs sign)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: cos (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: cosh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: exp (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: exp2 (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: expm1 (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fabs (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fdim (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: feclearexcept (excepts)
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: fegetexceptflag (flagp excepts)
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: fegetround ()
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: feraiseexcept (excepts)
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: fesetexceptflag (flagp excepts)
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: fetestexcept (excepts)
Package

with-c-syntax.libc.

Source

fenv.lisp.

Function: find-asdf-system-relative-file (base name)

See ‘find-with-c-syntax-default-include-file’

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: find-struct-spec (name)

* Syntax
~find-struct-spec~ name => struct-spec

* Arguments and Values
- name :: a symbol
- decl-spec :: a struct-spec instance, or nil.

* Description
Finds and returns a struct-spec. If no struct-specs are found, returns nil.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: find-typedef (name)

* Syntax
~find-typedef~ name => decl-spec

* Arguments and Values
- name :: a symbol
- decl-spec :: a decl-specs instance, or nil.

* Description
Finds and returns a typedef definition. If no typedefs are found, returns nil.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

typedef.lisp.

Function: floor (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fmax (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fmin (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fmod (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: fpclassify (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: frexp* (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: hypot (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: ilogb (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: invalidate-all-pseudo-pointers ()

This function invalidates all pseudo-pointers in the scope it called, and returns the number of invalidates pointers.

In ‘with-pseudo-pointer-scope’, this call invalidates pseudo-pointers made in that.
If out of that, this call invalidates all pseudo-pointers.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: isalnum (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isalpha (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isblank (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: iscntrl (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isdigit (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isfinite (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isgraph (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isgreater (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isgreaterequal (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isinf (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isless (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: islessequal (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: islessgreater (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: islower (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isnan (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isnormal (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isprint (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: ispunct (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isspace (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isunordered (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: isupper (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: isxdigit (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: ldexp (x exp)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: lerp (a b v)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: llround (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: log (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: log10 (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: log1p (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: log2 (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: logb (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: lround (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: make-pseudo-pointer (pointee &key initial-offset errorp)

Makes and returns a new pseudo-pointer points POINTEE. INITIAL-OFFSET is added to the result at making.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: make-struct (spec-obj &rest init-args)

* Syntax
~make-struct~ spec-obj &rest init-args => new-struct

* Arguments and Values
- spec-obj :: a symbol, or an instance of struct-spec.
- init-args :: objects.
- new-struct :: an instance of struct.

* Description
Makes a new struct instance based on the specification of ~spec-obj~.

If ~spec-obj~ is a symbol, it must be a name of a globally defined struct or union. To define a struct or an union globally, use ~with-c-syntax~ and declare it in a toplevel of translation-unit.

If ~spec-obj~ is an instance of struct-spec, it is used directly.

~init-args~ is used for initializing members of the newly created instance. If the number of ~init-args~ is less than the number of members, the rest members are initialized with the default values specified by the ~spec-obj~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: memchr (ptr ch count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: memcmp (lhs rhs count &key test predicate)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: memcpy (dest src count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: memmove (dest src count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: memset (dest ch count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: modf* (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: nan (&optional tagp)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: nextafter (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: nexttoward (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: null (object)

An alias for ‘CL:NULL’.
This is for convenience using ’NULL’ as C constant and Lisp function both when ‘intern’ the libc package.

Package

with-c-syntax.libc.

Source

stddef.lisp.

Function: parse-preprocessing-number (preprocessing-number)

Read a C numeric literal from ‘preprocessing-number’

Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: pow (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: preprocessing-number-p (object)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Reader: preprocessing-number-string (instance)
Writer: (setf preprocessing-number-string) (instance)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Target Slot

string.

Function: preprocessor (token-list reader-level readtable-case input-file-pathname)

This function preprocesses TOKEN-LIST before parsing.

Current workings are below:

- Interning a symbol into this package when it has a same name as C keywords or operators, or libc symbols.
READTABLE-CASE affects how to do it.

- Concatenation of string literals.

- Expands preprocessor macros defined by ’#defined’. (Undocumented now.)

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: pseudo-pointer-dereference (pointer)

Dereferences the POINTER and returns the pointed object.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: (setf pseudo-pointer-dereference) (pointer)

Makes the POINTER to point the NEW-OBJECT.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: pseudo-pointer-invalidate (pointer)

Makes the POINTER to point no objects. After that, calling ‘pseudo-pointer-dereference’ to this pointer will be error.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: pseudo-pointer-pointable-p (object)

Returns whether the OBJECT can directly be held by pseudo-pointers.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: remainder (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: remove-struct-spec (name)

* Syntax
~remove-struct-spec~ name => struct-spec

* Arguments and Values
- name :: a symbol
- struct-spec :: a struct-specs instance, or nil.

* Description
Removes a struct-spec definition named ~name~.

Returns the removed struct-spec definition. If no struct-specs are found, returns nil.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: remove-typedef (name)

* Syntax
~remove-typedef~ name => decl-spec

* Arguments and Values
- name :: a symbol
- decl-spec :: a decl-specs instance, or nil.

* Description
Removes a typedef definition named ~name~.

Returns the removed typedef definition. If no typedefs are found, returns nil.

* Affected By
~with-c-compilation-unit~.

Package

with-c-syntax.core.

Source

typedef.lisp.

Function: remquo* (x y)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: round (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: scalbln (x exp)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: scalbn (x exp)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: signbit (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: sin (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: sinh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: sqrt (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: strcat (dst src)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strchr (str ch)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strcmp (str1 str2)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strcpy (dst src)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strcspn (str reject)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strlen (str)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strncat (dst src count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strncmp (str1 str2 count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strncpy (dst src count)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strpbrk (str accept)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strrchr (str ch)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strspn (str accept)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strstr (haystack needle)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: strtok (str delim)
Package

with-c-syntax.libc.

Source

string.lisp.

Function: struct-member (struct member-name)

* Syntax
~struct-member~ struct member-name => object

* Arguments and Values
- struct :: an instance of struct
- member-name :: a symbol
- object :: an object

* Description
Returns the value of the member named ~member-name~ in the ~struct~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: (setf struct-member) (struct member-name)

* Syntax
(setf (~struct-member~ struct member-name) new-object)

* Arguments and Values
- struct :: an instance of struct
- member-name :: a symbol
- new-object :: an object

* Description
Sets the value of the member named ~member-name~ in the ~struct~.

Package

with-c-syntax.core.

Source

struct.lisp.

Function: tan (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: tanh (x)
Package

with-c-syntax.libc.

Source

math.lisp.

Function: tolower (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: toupper (char)
Package

with-c-syntax.libc.

Source

ctype.lisp.

Function: trunc (x)
Package

with-c-syntax.libc.

Source

math.lisp.


6.1.6 Standalone methods

Method: initialize-instance :before ((macro-definition function-like-macro) &rest args &key identifier-list variadicp replacement-list)
Source

preprocessor.lisp.

Method: initialize-instance :before ((macro-definition object-like-macro) &rest args &key replacement-list)
Source

preprocessor.lisp.

Method: initialize-instance :after ((macro-definition macro-definition) &rest args)
Source

preprocessor.lisp.

Method: initialize-instance :before ((macro-definition macro-definition) &rest args &key name)
Source

preprocessor.lisp.

Method: make-load-form ((pp-number preprocessing-number) &optional env)
Source

pp-number.lisp.

Method: make-load-form ((obj spec-qualifier-list) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj init-declarator) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((sspec struct-spec) &optional environment)
Source

struct.lisp.

Method: make-load-form ((obj struct-declarator) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj struct-or-union-spec) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj enumerator) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj param-decl) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj enum-spec) &optional environment)
Source

compiler.lisp.

Method: make-load-form ((obj decl-specs) &optional environment)
Source

compiler.lisp.

Method: print-object ((macro-definition function-like-macro) stream)
Source

preprocessor.lisp.

Method: print-object ((obj if-section) stream)
Source

preprocessor.lisp.

Method: print-object ((macro-definition object-like-macro) stream)
Source

preprocessor.lisp.

Method: (setf stream-file-position) ((cp-stream physical-source-input-stream))
Package

trivial-gray-streams.

Source

physical-source.lisp.

Method: stream-file-position ((cp-stream physical-source-input-stream))
Package

trivial-gray-streams.

Source

physical-source.lisp.

Method: stream-peek-char ((cp-stream physical-source-input-stream))
Package

sb-gray.

Source

physical-source.lisp.

Method: stream-read-char ((cp-stream physical-source-input-stream))
Package

sb-gray.

Source

physical-source.lisp.

Method: stream-unread-char ((cp-stream physical-source-input-stream) character)
Package

sb-gray.

Source

physical-source.lisp.


6.1.7 Conditions

Condition: with-c-syntax-error

The root class of all errors in with-c-syntax system.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

simple-error.

Direct subclasses
Condition: with-c-syntax-style-warning

Signalled when ‘with-c-syntax’ saw a kind of ‘style-warning’.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

style-warning.

Direct methods

with-c-syntax-style-warning-message.

Direct slots
Slot: message
Initargs

:message

Readers

with-c-syntax-style-warning-message.

Writers

This slot is read-only.

Condition: with-c-syntax-warning

The root type of all warnings in the with-c-syntax system.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

simple-warning.


6.1.8 Structures

Structure: preprocessing-number

A structure represents preprocessing-number token in the C standard.

Package

with-c-syntax.core.

Source

pp-number.lisp.

Direct superclasses

structure-object.

Direct methods
Direct slots
Slot: string
Package

common-lisp.

Readers

preprocessing-number-string.

Writers

(setf preprocessing-number-string).

Slot: parse-result
Readers

preprocessing-number-parse-result.

Writers

(setf preprocessing-number-parse-result).


6.1.9 Classes

Class: struct

* Class Precedence List
struct, standard-object, ...

* Description
A representation of C structs or unions.

Package

with-c-syntax.core.

Source

struct.lisp.

Direct methods
Direct slots
Slot: member-index-table
Initargs

:member-index-table

Readers

struct-member-index-table.

Writers

This slot is read-only.

Slot: member-vector
Initform

#()

Initargs

:member-vector

Readers

struct-member-vector.

Writers

(setf struct-member-vector).


6.1.10 Types

Type: enum ()

Represents the enum type.

Package

with-c-syntax.core.

Source

compiler.lisp.

Type: pseudo-pointer (&optional pointee-type)

The base type of internal representation of null and non-null pointers in with-c-syntax sysrem.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.


6.2 Internals


6.2.1 Constants

Constant: +numeric-type-symbols+

A list of symbols representing numeric types.

Package

with-c-syntax.core.

Source

compiler.lisp.

Constant: +numeric-types-alist+

An alist of (list-of-symbols . <lisp-type>), holding relationships between notations of C type and Common Lisp types.
For each entry of alist, its car is sorted alphabetically.

Package

with-c-syntax.core.

Source

compiler.lisp.

Constant: +placemaker-token+
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Constant: +pp-date-month-name+

A vector of month names following asctime() manner. Used by __DATE__

Package

with-c-syntax.core.

Source

predefined-macro.lisp.

Constant: +pseudo-pointer-mask+

A fixnum represents the bitmask splits the pseudo-pointer bit representation to the ’base part’ and the ’index part’.

The ’base part’ is used for a key of ‘*pseudo-pointee-table*’. The ’index part’ is used for a offset of the pointee value.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Constant: +pseudo-pointer-safebit+

A fixnum specifies the ’sign bit’ of the ’index part’ of the pseudo-pointer bit representation.

For the ’index part’, the representation is like here:

- #b1000000 :: 0
- #b1000001 - #b1111111 :: +1 ~ +63
- #b0111111 - #b0000000 :: -1 ~ -64

If the ’index part’ exceeds this limitation, the result is unpredictable.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Constant: +wcs-end-marker+
Package

with-c-syntax.core.

Source

reader.lisp.

Constant: +with-c-syntax-default-reader-level+
Package

with-c-syntax.core.

Source

reader.lisp.


6.2.2 Special variables

Special Variable: *c-parser*
Package

with-c-syntax.core.

Source

compiler.lisp.

Special Variable: *fexcept-register*

Internal storage of error flag for our floating-point error emulation.

Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Special Variable: *function-pointer-ids*

Holds a list of symbols, which are declared as a pointer
to a function. (Because such a symbol is specially treated by the function-calling expression.)

Package

with-c-syntax.core.

Source

compiler.lisp.

Special Variable: *next-pseudo-pointer*

A pseudo-pointer used for the next object.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Special Variable: *pseudo-pointee-table*

A hash-table holds relations between the ’base part’ of a pseudo-pointer and the pointee object.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Special Variable: *return-last-statement*

Specifies whether ‘with-c-syntax’ returns the last form’s value of compound statements or not.

Package

with-c-syntax.core.

Source

compiler.lisp.

Special Variable: *second-unread-char*

Holds a character wanted to ‘unread-char’ secondarily. This is used for implementing ’...’ and ’%:%:’.

Package

with-c-syntax.core.

Source

reader.lisp.

Special Variable: *strtok-target*

Used by |strtok|

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Special Variable: *struct-specs*

* Value Type
a hashtable :: a symbol -> a list of struct-spec.

* Description
Holds definitions of structs or unions.

* Notes
At the beginning of ~with-c-syntax~, it binds this variable to the values they held. This behavior limits the scope of local struct/union definitions into the compilation unit.

* Affected By
~with-c-compilation-unit~.

* See Also
~find-struct-spec~, ~add-struct-spec~, ~remove-struct-spec~

Package

with-c-syntax.core.

Source

struct.lisp.

Special Variable: *typedef-names*

* Value Type
a hashtable :: a symbol -> list of decl-specs

* Description
Holds definitions of typedefs.

* Notes
At the beginning of ~with-c-syntax~, it binds this variable to the values they held. This behavior limits the scope of local typedefs into the compilation unit.

* Affected By
~with-c-compilation-unit~.

* See Also
~find-typedef~, ~add-typedef~, ~remove-typedef~.

Package

with-c-syntax.core.

Source

typedef.lisp.

Special Variable: *wcs-expanding-environment*

‘with-c-syntax’ bind this to ‘&environment’ argument.

Package

with-c-syntax.core.

Source

compiler.lisp.

Special Variable: *with-c-syntax-preprocessor-process-digraph*

Determines whether preprocessor replaces digraphs.
If this is true, replacement occurs but ‘with-c-syntax-style-warning’ is signalled. If this is ‘:no-warn’, replacement occurs and the style-warning is not signalled.

Package

with-c-syntax.core.

Source

lexer.lisp.

Special Variable: *with-c-syntax-reader-process-backslash-newline*

Determines #{ }# reader deletes backslash-newline sequence. Deletion occurs if this is true.

Package

with-c-syntax.core.

Source

physical-source.lisp.

Special Variable: *with-c-syntax-reader-process-trigraph*

Determines whether #{ }# reader replaces C trigraphs.
If this is true, replacement occurs but ‘with-c-syntax-style-warning’ is signalled. If this is ‘:no-warn’, replacement occurs and the style-warning is not signalled.

Package

with-c-syntax.core.

Source

physical-source.lisp.


6.2.3 Macros

Macro: ashf (place shift)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: check-and-pop-pp-directive-token-1 (token-list directive-name errorp)

Used by ‘pop-preprocessor-directive-token’

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Macro: cond-let ((var1) &body clauses)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: define-c-syntax-reader-for-each-case-mode (base-readtable-name)
Package

with-c-syntax.core.

Source

reader.lisp.

Macro: define-case-aware-find-symbol (finder-function-name package-name &key upcased-package-name docstring)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Macro: define-case-aware-token-p-function (function-name find-symbol-function symbol)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Macro: define-errno-symbol (name)
Package

with-c-syntax.libc-implementation.

Source

errno.lisp.

Macro: define-find-c-readtable-name-methods (base-readtable-name level)
Package

with-c-syntax.core.

Source

reader.lisp.

Macro: divf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: lambda-ignoring-_ (lambda-list &body body)

Works like ‘cl:lambda’ macro except automatically ‘declare’s ‘ignore’ for parameters beginning with ’_’ character.

Package

with-c-syntax.core.

Source

util.lisp.

Macro: logandc2f (place i)
Package

with-c-syntax.libc-implementation.

Source

util.lisp.

Macro: logandf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: logiorf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: logiorf (place &rest args)
Package

with-c-syntax.libc-implementation.

Source

util.lisp.

Macro: logxorf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: make-pseudo-pointer-to-place (place)

Makes a pseudo-pointer using ‘pseudo-pointer-to-place’.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Macro: make-trimed-vectorf (place trim-position)

Modify macro of ‘make-trimed-vector’

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Macro: modf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: mulf (place &rest args)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: mv-cond-let ((&optional var1 &rest rest-vars) &body clauses)

This is like the famous ’COND-LET’, but takes multiple values.

Package

with-c-syntax.core.

Source

util.lisp.

Macro: nest (&rest things)

Macro to do keep code nesting and indentation under control.

Package

with-c-syntax.core.

Source

util.lisp.

Macro: nreconcf (place list)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: pop-last-preprocessor-directive-token (token-list directive-name)

For #ifdef, #ifndef, and #undef

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Macro: pop-next-newline (token-list)

Pop the direcive’s newline for setting next line’s line-number to same.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Macro: pop-preprocessor-directive-token (token-list directive-name &key errorp)

Pops the next token in TOKEN-LIST ignoring ‘+whitespace-marker+’

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Macro: post-incf (form &optional delta)

A post increment version of ‘incf’.

Package

with-c-syntax.core.

Source

util.lisp.

Macro: push-right (place i)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: resize-stringf (place size)

Modify macro of ‘resize-string’

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Macro: revappendf (place list)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: reverse-ashf (place shift)
Package

with-c-syntax.core.

Source

util.lisp.

Macro: with-c-compilation-unit ((&key return-last-statement) &body body)

Establishes variable bindings for a new compilation.

Package

with-c-syntax.core.

Source

compiler.lisp.

Macro: with-fmax-fmin-parameter-check ((x y) &body body)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Macro: with-log-error-handling (() &body body)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Macro: with-mod-family-error-handling ((x y) &body body)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Macro: with-nearest-int-error-handling ((x) &body body)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Macro: with-preprocessor-state-slots ((state) &body body)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Macro: with-wcs-math-error-handling ((var-or-var-list (function x &optional y) &rest keyargs &key underflow-value) &body body)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.


6.2.4 Ordinary functions

Function: %expand-translation-unit-splitter-key (unit)

Used by ‘expand-translation-unit’

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: %make-param-decl (&key decl-specs init-declarator)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: %make-pp-to-place (&key lambda)
Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: _-symbol-p (obj)

Returns T if OBJ is a symbol and starts with ’_’ character.

Package

with-c-syntax.core.

Source

util.lisp.

Function: add-local-preprocessor-macro (state symbol macro-definition)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: add-to-tail (lis i)
Package

with-c-syntax.core.

Source

util.lisp.

Function: array-dimension-combine (array-dimension-list init)

Resolves unspecified dimensions with an initializer.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: assign-wcs-fexcept (dst src)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Function: begin-if-section (state condition-form eval-result)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: c-type-to-lisp-type-declaration-hack (type)

Treats some special type handlings for valid C code.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: call-with-wcs-math-error-handler (function args &key underflow-value &allow-other-keys)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: check-in-if-section (state directive-symbol)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: check-nextafter-result (ret x)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: check-no-preprocessor-token (token-list directive-name)

Checks no preprocessing token is left in TOKEN-LIST.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: check-wcs-math-result (ret arg-list)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: collect-_-symbol-in-lambda-list (lambda-list)

Collects symbols starting with ’_’ character in LAMBDA-LIST.

Package

with-c-syntax.core.

Source

util.lisp.

Function: collect-function-like-macro-identifier-list (token-list &optional directive-symbol)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: collect-one-macro-argument (token-list macro-alist)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: collect-preprocessor-macro-arguments (token-list macro-alist)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: compute-function-return-type (name return-decl-specs)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: concatenate-comma-list (lis op i)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-decl-specs (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-enum-spec (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-enumerator (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-function-definition (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-init-declarator (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-lisp-type-declaration-table (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-param-decl (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-pp-macro-argument (instance)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: copy-preprocessing-number (instance)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: copy-pseudo-pointer-to-place (instance)
Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: copy-spec-qualifier-list (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-stat (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-struct-declarator (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-struct-or-union-spec (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: copy-struct-spec (instance)
Package

with-c-syntax.core.

Source

struct.lisp.

Function: copy-wcs-fexcept (instance)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Reader: decl-specs-enum-bindings (instance)
Writer: (setf decl-specs-enum-bindings) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

enum-bindings.

Reader: decl-specs-lisp-type (instance)
Writer: (setf decl-specs-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

lisp-type.

Function: decl-specs-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Reader: decl-specs-qualifier (instance)
Writer: (setf decl-specs-qualifier) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

qualifier.

Reader: decl-specs-storage-class (instance)
Writer: (setf decl-specs-storage-class) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

storage-class.

Reader: decl-specs-struct-spec (instance)
Writer: (setf decl-specs-struct-spec) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

struct-spec.

Reader: decl-specs-tag (instance)
Writer: (setf decl-specs-tag) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

tag.

Reader: decl-specs-type-spec (instance)
Writer: (setf decl-specs-type-spec) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

type-spec.

Reader: decl-specs-typedef-init-decl (instance)
Writer: (setf decl-specs-typedef-init-decl) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

typedef-init-decl.

Function: delete-consecutive-whitespace-marker (token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: delete-symbols-from-function-pointer-ids (symbols)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: delete-whitespace-marker (token-list)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: dimension-list-max-dimensions (lis)

Calculates max lengths per depth of a nested list, like ‘array-dimensions’

Package

with-c-syntax.core.

Source

util.lisp.

Function: draw-preprocessor-directive-line-tokens (state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: earmuff-lengthes (string earmuff-char)

Calculates ’*earmuff*’ lengthes in STRING with EARMUFF-CHAR, and returns it lengthes in front and in last.

e.g. (earmuff-lengthes "*foo**" #*) ; => (values 1 2)

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Reader: enum-spec-enumerator-list (instance)
Writer: (setf enum-spec-enumerator-list) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

enumerator-list.

Reader: enum-spec-id (instance)
Writer: (setf enum-spec-id) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

id.

Function: enum-spec-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-declarator (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-declarator) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-function-pointer-p (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-function-pointer-p) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-initializer (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-initializer) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-lisp-initform (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-lisp-initform) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-lisp-name (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-lisp-name) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-lisp-type (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf enumerator-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: enumerator-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: error-lisp-subscript (obj)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: eval-if-expression (directive-symbol directive-token-list state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-c-syntax (body try-add-{})
Package

with-c-syntax.core.

Source

with-c-syntax.lisp.

Function: expand-compound-stat-into-stat (stat return-last-statement)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-concatenate-operator (token1-list token2-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-declarator-bindings (lexical-binds dynamic-extent-vars ignored-names special-vars type-decls)

Makes a (let* (...) (declare ...)) form except trying to simplify the expansion.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-declarator-to-nest-macro-elements (mode decls)

Expand a list of declarators to a ‘nest’ macro element. MODE is one of ‘:statement’ or ‘:translation-unit’

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-defined-operator (token-list macro-alist directive-symbol)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-each-preprocessor-macro-in-list (token-list macro-alist pp-state)

Used by ‘expand-macro-argument’, #line and #include.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-function-like-macro (macro-definition rest-token-list macro-alist pp-state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-global-function-definition-to-nest-macro-element (fdef-list)

Used by ‘expand-translation-unit’

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-if-statement-into-stat (exp then-stat &optional else-stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-init-declarator-init (dspecs abst-declarator initializer &key allow-incomplete)

Finds the specified type and the initialization form. Returns (values var-init var-type).

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-init-decls (mode decl-specs init-decls)

A part of ‘expand-declarator-to-nest-macro-elements’.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-lisp-with-stat-into-stat (identifier lisp-expression stat)

Handles with-c-syntax extension syntax for ’with-’ like macros.
Expands " id lisp-expression statement " to ‘(,id ,@lisp-expression ,@statement)

Example:
with-output-to-string ((*standard-output*)) { princ ( "Hello, World!" ) ; } ; => (with-output-to-string (*standard-output*) (princ "Hello, World!"))

Note: This loose expansion causes weird but interesting results.
See test codes in test/stmt.lisp

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-loop-into-stat (body-stat &key init cond step post-test-p)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-macro-argument (pp-macro-argument pp-state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-macro-replacement-list (replacement-list macro-arg-alist)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-object-like-macro (macro-definition)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-predefined-macro (predefined-macro pp-state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-preprocessor-macro (token rest-token-list macro-alist pp-state)

Expand preprocessor macro named TOKEN. If it is a function-like
macro, its arguments are taken from REST-TOKEN-LIST. MACRO-ALIST is an
alist of preprocessor macro definitions. PP-STATE is a
‘preprocessor-state’ object, used for expanding predefined macros.

Returns four values:
1. A list of tokens made by expansion.
2. A list, tail of REST-TOKEN-LIST, left after collecting function-like macro arguments. 3. An alist derived from MACRO-ALIST changed after expansion.
4. A boolean tells whether TOKEN is a function-like-macro but
REST-TOKEN-LIST is not a form of invocation.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-statement-expression (stat)

Expands GCC’s statement expression, not in C90.
See https://gcc.gnu.org/onlinedocs/gcc/Statement-Exprs.html

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-static-function-definition-to-nest-macro-element (fdef-list)

Used by ‘expand-translation-unit’

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-stringify-operator (token macro-arg-alist)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: expand-switch-into-stat (exp stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-toplevel-const-exp (exp)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-toplevel-stat (stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: expand-translation-unit (units)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-decl-specs (dspecs)

Checks and fills the passed decl-specs.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-enum-spec (espec dspecs)

Fills the decl-specs object referring the passed enum-spec.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-init-declarator (dspecs init-decl)

Fills the passed init-declarator object.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-numeric-type-spec (dspecs type-spec-list)

Fills the decl-specs object referring the passed numeric TYPE-SPEC-LIST.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-struct-or-union-spec (suspec dspecs)

Fills the decl-specs object referring the passed struct-or-union-spec. If required, makes a new struct-spec object.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: finalize-type-spec (dspecs)

A part of ‘finalize-decl-specs’. This processes type-spec.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: find-c-readtable (level readtable-case)

Returns a readtable for tokenize C source. See ‘*with-c-syntax-reader-level*’.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: find-c-terminal (string &optional readtable-case)

Find a symbol in ‘WITH-C-SYNTAX.SYNTAX’ package having a same NAME. If not found, returns ‘nil’.

Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: find-digraph-replacement (punctuator)
Package

with-c-syntax.core.

Source

lexer.lisp.

Function: find-errno-symbol (name)
Package

with-c-syntax.libc-implementation.

Source

errno.lisp.

Function: find-include-<header>-file (header-name &key errorp)

Finds a file specified by #include <...> style header-name with pathnames got by ‘*with-c-syntax-find-include-file-function-list*’.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: find-include-header-file (header-name &key errorp)

Finds a file specified by #include "..." style header-name. Current strategy is just to use ‘cl:probe-file’. So it will affected by ‘*default-pathname-defaults*’.
If no file was found, ‘find-include-<header>-file’ is called.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: find-lisp-type-by-c-floating-suffix (suffix)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: find-numeric-literal-type (pp-number-string)

Looks PP-NUMBER-STRING and returns its radix (integer) and a boolean whether its type is float or not.

Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: find-operator-on-prefix (operator symbol)

This function tries to find OPERATOR in front of SYMBOL.
If found, it returns T and list of of splited symbols. If not found, it returns NIL.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: find-operator-on-suffix (operator symbol)

This function tries to find OPERATOR in back of SYMBOL.
If found, it returns T and list of of splited symbols. If not found, it returns NIL.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: find-pp-operator-name (string &optional readtable-case)

Find a symbol in ‘WITH-C-SYNTAX.PREPROCESS-OPERATOR’ package having a same NAME. If not found, returns ‘nil’.

Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: find-pragma-name (string &optional readtable-case)

Find a symbol in ‘WITH-C-SYNTAX.PRAGMA-NAME’ package having a same NAME. If not found, returns ‘nil’.

Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: find-preprocessor-directive (string &optional readtable-case)

Find a symbol in ‘WITH-C-SYNTAX.PREPROCESSOR-DIRECTIVE’ package having a same NAME. If not found, returns ‘nil’.

Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: find-punctuator (name &optional process-digraph?)
Package

with-c-syntax.core.

Source

lexer.lisp.

Function: find-trigraph-character-by-last-character (char)
Package

with-c-syntax.core.

Source

physical-source.lisp.

Function: find-with-c-syntax-default-include-file (name)

Makes a pathname of the directory containing with-c-syntax include files. This function is used for making the default value of ‘*with-c-syntax-find-include-file-function-list*’

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: float-subnormal-p (x)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Reader: function-definition-func-args (instance)
Writer: (setf function-definition-func-args) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

func-args.

Reader: function-definition-func-body (instance)
Writer: (setf function-definition-func-body) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

func-body.

Reader: function-definition-func-name (instance)
Writer: (setf function-definition-func-name) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

func-name.

Reader: function-definition-lisp-type (instance)
Writer: (setf function-definition-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

lisp-type.

Function: function-definition-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Reader: function-definition-storage-class (instance)
Writer: (setf function-definition-storage-class) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

storage-class.

Function: function-like-macro-invocation-p (token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: function-parameter-void-p (func-param)

Checks the function parameter list is ’(void)’ or not.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: generate-lisp-type-declarations (lisp-type-declaration-table)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: get-c-readtable-level (readtable)

Calculate the readtable-level (described in ‘*with-c-syntax-reader-level*’ docstring) of the READTABLE. If READTABLE is not for C syntax, returns NIL.

Package

with-c-syntax.core.

Source

reader.lisp.

Reader: init-declarator-declarator (instance)
Writer: (setf init-declarator-declarator) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

declarator.

Reader: init-declarator-function-pointer-p (instance)
Writer: (setf init-declarator-function-pointer-p) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

function-pointer-p.

Reader: init-declarator-initializer (instance)
Writer: (setf init-declarator-initializer) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

initializer.

Reader: init-declarator-lisp-initform (instance)
Writer: (setf init-declarator-lisp-initform) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

lisp-initform.

Reader: init-declarator-lisp-name (instance)
Writer: (setf init-declarator-lisp-name) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

lisp-name.

Reader: init-declarator-lisp-type (instance)
Writer: (setf init-declarator-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

lisp-type.

Function: init-declarator-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: intern-conc-pp-number (str1 str2 &optional package)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: lisp-subscript (obj arg1 &rest args)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf lisp-subscript) (obj arg1 &rest args)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lisp-type-declaration-table-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Reader: lisp-type-declaration-table-table (instance)
Writer: (setf lisp-type-declaration-table-table) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

table.

Function: lispify-address-of (exp)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-binary (op)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-cast (type exp)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-funcall (func-exp args)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-function-definition (name body-stat &key k&r-decls return)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-offsetof (dspecs id)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-type-name (spec-qual abs)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: lispify-unary (op)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: list-lexer (token-list)
Package

with-c-syntax.core.

Source

lexer.lisp.

Function: macro-control-marker-p (token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: macro-scoping-marker-p (token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: make-decl-specs (&key type-spec storage-class qualifier lisp-type tag typedef-init-decl enum-bindings struct-spec)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-dimension-list (dims &optional default)

Constructs a nested list like ‘make-array’.

Package

with-c-syntax.core.

Source

util.lisp.

Function: make-dimension-list-load-form (lis max-depth)

Makes a load form of a nested list.

Package

with-c-syntax.core.

Source

util.lisp.

Function: make-enum-spec (&key id enumerator-list)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-enumerator (&key declarator initializer lisp-name lisp-initform lisp-type function-pointer-p)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-function-definition (&key func-name storage-class func-args func-body lisp-type)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-init-declarator (&key declarator initializer lisp-name lisp-initform lisp-type function-pointer-p)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-lisp-type-declaration-table (&key table)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-macro-arguments-alist (macro-definition macro-arg-list)

Makes an alist of (<symbol> . <macro-argument>) for function-like-macro expansion.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: make-param-decl (&key decl-specs declarator)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-pp-macro-argument (&key token-list token-list-expansion macro-alist)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: make-preprocessing-number (&key string parse-result)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: make-reduced-dimension-array (array &rest subscripts)

Makes a displaced array which has a reduced dimensions.

Example: Consider what is returned by (make-reduced-dimension-array (make-array ’(2 2 2)) ’(1))

Its dimension is ’(2 2), and it is a displaced array aliasing from ’(1 0 0) to ’(1 2 2) in the original array.

Package

with-c-syntax.core.

Source

util.lisp.

Function: make-spec-qualifier-list (&key type-spec storage-class qualifier lisp-type tag typedef-init-decl enum-bindings struct-spec)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-stat (&key code declarations break-statements continue-statements case-label-list)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-stat-unresolved-break ()
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-stat-unresolved-continue ()
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-struct-declarator (&key declarator initializer lisp-name lisp-initform lisp-type function-pointer-p bits)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-struct-or-union-spec (&key type id struct-decl-list)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: make-struct-spec (&key struct-name union-p member-defs defined-in-this-unit)
Package

with-c-syntax.core.

Source

struct.lisp.

Function: make-trimed-vector (vector trim-position &optional end)

Trims the head TRIM-POSITION elements of VECTOR, using ‘displaced-array’. If END supplied, its tail is also trimed (using ‘displaced-array’, too).

This function is used for emulating C string truncation with pointer movements.

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Function: make-wcs-fexcept (&key flags)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Function: mantissa-radix-change (mantissa from-radix to-radix)
Package

with-c-syntax.libc-implementation.

Source

float.lisp.

Function: merge-lisp-type-declaration-table (lisp-type-declaration-table1 lisp-type-declaration-table2)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: merge-stat (s1 s2)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: not-eql (x y)

Used for ’!=’ of C language.

Package

with-c-syntax.core.

Source

util.lisp.

Function: nreconc-to (tail list)

Calls nreconc with reversed order args. A helper for ‘nreconcf’.

Package

with-c-syntax.core.

Source

util.lisp.

Reader: param-decl-decl-specs (instance)
Writer: (setf param-decl-decl-specs) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

decl-specs.

Reader: param-decl-init-declarator (instance)
Writer: (setf param-decl-init-declarator) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

init-declarator.

Function: param-decl-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: parse-decimal-floating-constant (pp-number-string)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: parse-function-parameter-list (func-param)

Parses FUNC-PARAM as a list of ‘param-decl’ structure (C function parameter list), returns 5 values.
1. A list of symbols naming the parameter.
2. A list of types representing the types of parameters. 3. A symbol naming the variadic argument if requested.
4. A list of symbols should be ‘ignore’d.
5. A ‘lisp-type-declaration-table’ object.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: parse-header-name (token-list directive-symbol try-pp-macro-expand macro-alist pp-state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: parse-hexadecimal-floating-constant (pp-number-string)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: parse-in-with-c-syntax-readtable-parameter-token (token)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: parse-in-with-c-syntax-readtable-parameters (token1 token2)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: parse-integer-constant (pp-number-string radix)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: parse-integer-suffix (pp-number-string suffix-start-index)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: parse-line-arguments (token-list directive-symbol try-pp-macro-expand macro-alist pp-state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: pow-result-significantly-complex-p (ret x y)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: pp-defined-operator-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: pp-if-expression-lexer (token-list)
Package

with-c-syntax.core.

Source

lexer.lisp.

Reader: pp-macro-argument-macro-alist (instance)
Writer: (setf pp-macro-argument-macro-alist) (instance)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Target Slot

macro-alist.

Function: pp-macro-argument-p (object)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Reader: pp-macro-argument-token-list (instance)
Writer: (setf pp-macro-argument-token-list) (instance)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Target Slot

token-list.

Reader: pp-macro-argument-token-list-expansion (instance)
Writer: (setf pp-macro-argument-token-list-expansion) (instance)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Target Slot

token-list-expansion.

Function: pp-once-pragma-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: pp-pragma-directive-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: pp-pragma-operator-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: pp-stdc-pragma-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Function: pp-with-c-syntax-pragma-p (token &optional readtable-case)
Package

with-c-syntax.core.

Source

case-aware-find-symbol.lisp.

Reader: preprocessing-number-parse-result (instance)
Writer: (setf preprocessing-number-parse-result) (instance)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Target Slot

parse-result.

Function: preprocessor-loop (state)

See ‘preprocessor’

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-loop-at-directive-p (state token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-loop-concatenate-string (state token)

Do the translation phase 6 – string concatenation.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-loop-do-directives (state)

Process preprocessor directives. This is tranlation phase 4.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-loop-do-pragma-operator (state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-macro-exists-p (macro-alist symbol)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-token-exists-p (token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: preprocessor-try-split (symbol)

This function tries to find some C operators in SYMBOL.
If found, it returns T and list of splited symbols. If not found, it returns NIL.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: process-reader-pragma (token-list)

Process pragmas affects with-c-syntax readers.
See ‘process-with-c-syntax-pragma’ for preprocessor pragmas.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: process-stdc-pragma (directive-symbol directive-token-list state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: process-with-c-syntax-pragma (directive-symbol directive-token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: pseudo-pointer-extract (pointer &optional errorp)

A helper function used by ‘pseudo-pointer-dereference’, etc.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Reader: pseudo-pointer-to-place-lambda (instance)
Writer: (setf pseudo-pointer-to-place-lambda) (instance)
Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Target Slot

lambda.

Function: pseudo-pointer-to-place-p (object)
Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Function: push-case-label (case-label-exp stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: push-lisp-type-declaration-table (lisp-type-declaration-table type name)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: raise-no-preprocessor-token-error (directive-name)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: read-% (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-0x-numeric-literal (stream c0)

Read hexadecimal numeric literal of C.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-< (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-after-unread (unread-char stream &optional eof-error-p eof-value recursive-p)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-colon (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-dot (stream char)

Dot may be an ’.’ operator, ’...’, or a prefix of floating numbers.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-double-quote (stream &optional c0)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-escaped-char (stream)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-in-c-syntax (stream char n)

Called by ’#{’ reader macro of ‘with-c-syntax-readtable’.
Inside ’#{’ and ’}#’, the reader uses completely different syntax, and the result is wrapped with ‘with-c-syntax’.
See ‘*with-c-syntax-reader-level*’ and ‘*with-c-syntax-reader-case*’.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-in-previous-readtable (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-l (stream &optional char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-lonely-single-symbol (stream char)

If the next character in STREAM is terminating, returns a symbol made of CHAR. If not, returns a next token by ‘cl:read’ after unreading CHAR.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-minus (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-numeric-escape (stream radix &key limit)

Used by ‘read-escaped-char’.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-plus-like-symbol (stream char)

For ’+’, ’&’, ’|’. They may be ’+’, ’++’, or ’+=’

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-preprocessing-number (stream &optional first-char)

Reads a preprocessing number token, defined in
"6.4.8 Preprocessing numbers" in ISO/IEC 9899:1999.
If FIRST-CHAR is supplied, it is read as the first char. This feature is for the convension of reader macro functions.

Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: read-preprocessing-number-from-string (string &key junk-allowed)
Package

with-c-syntax.core.

Source

pp-number.lisp.

Function: read-preprocessing-token (stream keep-whitespace recursive-p)

Reads a token from STREAM until EOF or ’}#’ found. Newline is read as ‘+newline-marker+’.
If KEEP-WHITESPACE is nil, whitespaces except newlines are ignored. (This feature is intended to suppress ‘+whitespace-marker+’ in the macro expansion, for debugging.)

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-right-curly-bracket (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-sharp (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-sharp-as-dispatching-macro (stream char num-arg)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-shift (stream char)

For ’<’, ’>’. They may be ’>’, ’>>’, and ’>=’, ’>>=’.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-single-character-symbol (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-single-or-compound-assign (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-single-quote (stream &optional c0)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-slash (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-slash-comment (stream char &optional next-function)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-solely-bar (stream char)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: read-universal-character-name (stream number-of-digits)

Reads unnnn or Unnnnnnnn syntax.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: ref-dimension-list (lis dim-1 &rest dims)

Accesses a nested list like ‘aref’, as a multi-dimensional array.

Package

with-c-syntax.core.

Source

util.lisp.

Function: (setf ref-dimension-list) (lis dim-1 &rest dims)

Accesses a nested list like ‘aref’, as a multi-dimensional array.

Package

with-c-syntax.core.

Source

util.lisp.

Function: remove-local-preprocessor-macro (state symbol)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: remove-whitespace-marker (token-list)
Package

with-c-syntax.core.

Source

reader.lisp.

Function: replacement-list-equal (list1 list2)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: resize-string (string size)

Resize STRING to SIZE using ‘adjust-array’ or ‘fill-pointer’.
This function is used for emulating C string truncation with NUL char.

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Function: revappend-to (tail list)

Calls revappend with reversed order args. A helper for ‘revappendf’.

Package

with-c-syntax.core.

Source

util.lisp.

Function: reverse-ash (i c)
Package

with-c-syntax.core.

Source

util.lisp.

Function: rewrite-break-statements (sym stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: rewrite-continue-statements (sym stat)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: setup-init-list (dims dspecs abst-declarator init)

Makes a list for ‘:initial-contents’ of ‘make-array’, from initializer-list.

Package

with-c-syntax.core.

Source

compiler.lisp.

Function: signed-byte-max (bits)
Package

with-c-syntax.libc-implementation.

Source

limits.lisp.

Function: signed-byte-min (bits)
Package

with-c-syntax.libc-implementation.

Source

limits.lisp.

Function: skip-c-whitespace (stream)

Skips C whitespaces except newline.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: spec-qualifier-list-enum-bindings (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-enum-bindings) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-lisp-type (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-qualifier (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-qualifier) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-storage-class (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-storage-class) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-struct-spec (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-struct-spec) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-tag (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-tag) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-type-spec (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-type-spec) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: spec-qualifier-list-typedef-init-decl (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf spec-qualifier-list-typedef-init-decl) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: split-concatenate-operator-left-operand (token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: split-concatenate-operator-right-operand (token-list)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: split-list-at (n list)

Return first N elements and rests of LIST.

Package

with-c-syntax.core.

Source

util.lisp.

Function: split-to-consecutive-parts (list &key test key)

Split LIST to consecutive parts testing with TEST.

(split-to-consecutive-parts ’(1 1 2 2 3)) ;; => ((1 1) (2 2) (3)) (split-to-consecutive-parts ’(1 1 1)) ;; => ((1 1 1)) (split-to-consecutive-parts nil) ;; => nil

Package

with-c-syntax.core.

Source

util.lisp.

Reader: stat-break-statements (instance)
Writer: (setf stat-break-statements) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

break-statements.

Reader: stat-case-label-list (instance)
Writer: (setf stat-case-label-list) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

case-label-list.

Reader: stat-code (instance)
Writer: (setf stat-code) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

code.

Reader: stat-continue-statements (instance)
Writer: (setf stat-continue-statements) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

continue-statements.

Reader: stat-declarations (instance)
Writer: (setf stat-declarations) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

declarations.

Function: stat-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: step-double-float-minus (x)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: step-double-float-plus (x)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: strchr* (str ch from-end)

Used by ‘|strchr|’ and ‘|strrchr|’

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Function: strcmp* (str1 str1-len str2 str2-len)

Used by ‘|strcmp|’ and ‘|strncmp|’

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Function: strcspn* (str reject)

Finds the position of the end of rejected chars in STR. If no such chars, return NIL.

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Function: stringify-conced-integer (int)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: strspn* (str accept)

Finds the position of the end of acceptable chars in STR. If no such chars, return NIL.

Package

with-c-syntax.libc-implementation.

Source

string.lisp.

Reader: struct-declarator-bits (instance)
Writer: (setf struct-declarator-bits) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

bits.

Function: struct-declarator-declarator (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-declarator) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-function-pointer-p (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-function-pointer-p) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-initializer (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-initializer) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-lisp-initform (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-lisp-initform) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-lisp-name (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-lisp-name) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-lisp-type (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: (setf struct-declarator-lisp-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-declarator-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Function: struct-member-index (struct member-name)

Returns the index of ~member-name~ in the internal storage of ~struct~.

Package

with-c-syntax.core.

Source

struct.lisp.

Reader: struct-or-union-spec-id (instance)
Writer: (setf struct-or-union-spec-id) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

id.

Function: struct-or-union-spec-p (object)
Package

with-c-syntax.core.

Source

compiler.lisp.

Reader: struct-or-union-spec-struct-decl-list (instance)
Writer: (setf struct-or-union-spec-struct-decl-list) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

struct-decl-list.

Reader: struct-or-union-spec-type (instance)
Writer: (setf struct-or-union-spec-type) (instance)
Package

with-c-syntax.core.

Source

compiler.lisp.

Target Slot

type.

Reader: struct-spec-defined-in-this-unit (instance)
Writer: (setf struct-spec-defined-in-this-unit) (instance)
Package

with-c-syntax.core.

Source

struct.lisp.

Target Slot

defined-in-this-unit.

Reader: struct-spec-member-defs (instance)
Writer: (setf struct-spec-member-defs) (instance)
Package

with-c-syntax.core.

Source

struct.lisp.

Target Slot

member-defs.

Function: struct-spec-p (object)
Package

with-c-syntax.core.

Source

struct.lisp.

Reader: struct-spec-struct-name (instance)
Writer: (setf struct-spec-struct-name) (instance)
Package

with-c-syntax.core.

Source

struct.lisp.

Target Slot

struct-name.

Reader: struct-spec-union-p (instance)
Writer: (setf struct-spec-union-p) (instance)
Package

with-c-syntax.core.

Source

struct.lisp.

Target Slot

union-p.

Function: take-consecutive-part (list &key test key)

Takes a first consecutive parts of LIST testing with TEST and returns the head and tail.

(take-consecutive-part ’(1 1 2 2 3)) ;; => (1 1) (2 2 3) (take-consecutive-part ’(1 1 1)) ;; => (1 1 1) nil (take-consecutive-part nil) ;; => nil nil

Package

with-c-syntax.core.

Source

util.lisp.

Function: terminating-char-p (char &optional readtable)

Returns T if CHAR is a terminating character in READTABLE.

Package

with-c-syntax.core.

Source

util.lisp.

Function: test-wcs-fexcept-flags (excepts wcs-fexcept)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Function: token-equal-p (token name)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: tokenize-included-source-file (header-name state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Function: tokenize-source (stream end-with-bracket-sharp &optional *readtable*)

Tokenize C source by doing translation phase 1, 2, and 3.
‘*readtable*’ must be bound to the C syntax readtable, got by ‘find-c-readtable’.

Package

with-c-syntax.core.

Source

reader.lisp.

Function: unsigned-byte-max (bits)
Package

with-c-syntax.libc-implementation.

Source

limits.lisp.

Function: va-args-identifier-p (token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Reader: wcs-fexcept-flags (instance)
Writer: (setf wcs-fexcept-flags) (instance)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Target Slot

flags.

Function: wcs-fexcept-p (object)
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Function: wcs-raise-fe-exception (fe-constant &key errno)
Package

with-c-syntax.libc-implementation.

Source

math.lisp.

Function: whitespace-like-token-p (token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.


6.2.5 Generic functions

Generic Function: adjust-newline-gap (stream newline-count)
Package

with-c-syntax.core.

Source

physical-source.lisp.

Methods
Method: adjust-newline-gap ((cp-stream physical-source-input-stream) newline-count)
Method: adjust-newline-gap (stream newline-count)
Generic Function: check-replacement-list-equal (mdef1 mdef2 name)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Methods
Method: check-replacement-list-equal ((mdef1 macro-definition) (mdef2 macro-definition) name)
Generic Function: check-valid-macro-redefinition (macro-definition1 macro-definition2 name)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Methods
Method: check-valid-macro-redefinition ((mdef1 function-like-macro) (mdef2 function-like-macro) name)
Method: check-valid-macro-redefinition ((mdef1 object-like-macro) (mdef2 object-like-macro) name)
Method: check-valid-macro-redefinition (mdef1 mdef2 name)
Generic Function: concatenate-token (token1 token2)

Perform token concatenation caused by ’##’ operator.

Package

with-c-syntax.core.

Source

preprocessor.lisp.

Methods
Method: concatenate-token ((token1 integer) (token2 preprocessing-number))
Method: concatenate-token ((token1 preprocessing-number) (token2 integer))
Method: concatenate-token ((token1 symbol) (token2 preprocessing-number))
Method: concatenate-token ((token1 preprocessing-number) (token2 symbol))
Method: concatenate-token ((token1 preprocessing-number) (token2 preprocessing-number))
Method: concatenate-token ((token1 integer) (token2 integer))
Method: concatenate-token ((token1 integer) (token2 symbol))
Method: concatenate-token ((token1 symbol) (token2 integer))
Method: concatenate-token ((token1 symbol) (token2 symbol))
Method: concatenate-token (token1 (token2 (eql with-c-syntax.core::||)))
Method: concatenate-token ((token1 (eql with-c-syntax.core::||)) token2)
Method: concatenate-token (token1 token2)
Generic Function: count-physical-source-buffered-char (cp-stream)
Package

with-c-syntax.core.

Methods
Method: count-physical-source-buffered-char ((cp-stream physical-source-input-stream))
Source

physical-source.lisp.

Generic Function: find-c-readtable-name (level readtable-case)

Finds a readtable name by arguments. See ‘find-c-readtable’.

Package

with-c-syntax.core.

Source

reader.lisp.

Methods
Method: find-c-readtable-name ((level (eql 2)) (readtable-case (eql :invert)))
Method: find-c-readtable-name ((level (eql 2)) (readtable-case (eql :preserve)))
Method: find-c-readtable-name ((level (eql 2)) (readtable-case (eql :downcase)))
Method: find-c-readtable-name ((level (eql 2)) (readtable-case (eql :upcase)))
Method: find-c-readtable-name ((level (eql 2)) (readtable-case (eql nil)))
Method: find-c-readtable-name ((level (eql 1)) (readtable-case (eql :invert)))
Method: find-c-readtable-name ((level (eql 1)) (readtable-case (eql :preserve)))
Method: find-c-readtable-name ((level (eql 1)) (readtable-case (eql :downcase)))
Method: find-c-readtable-name ((level (eql 1)) (readtable-case (eql :upcase)))
Method: find-c-readtable-name ((level (eql 1)) (readtable-case (eql nil)))
Method: find-c-readtable-name ((level (eql 0)) (readtable-case (eql :invert)))
Method: find-c-readtable-name ((level (eql 0)) (readtable-case (eql :preserve)))
Method: find-c-readtable-name ((level (eql 0)) (readtable-case (eql :downcase)))
Method: find-c-readtable-name ((level (eql 0)) (readtable-case (eql :upcase)))
Method: find-c-readtable-name ((level (eql 0)) (readtable-case (eql nil)))
Generic Reader: function-like-macro-identifier-list (object)
Package

with-c-syntax.core.

Methods
Reader Method: function-like-macro-identifier-list ((function-like-macro function-like-macro))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

identifier-list.

Generic Reader: function-like-macro-variadicp (object)
Package

with-c-syntax.core.

Methods
Reader Method: function-like-macro-variadicp ((function-like-macro function-like-macro))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

variadicp.

Generic Function: if-section-add-group (if-section form result)
Package

with-c-syntax.core.

Methods
Method: if-section-add-group (if-section form result)
Source

preprocessor.lisp.

Generic Function: if-section-processed-p (if-section)
Package

with-c-syntax.core.

Methods
Method: if-section-processed-p (if-section)
Source

preprocessor.lisp.

Generic Reader: lexer-error-token (condition)
Package

with-c-syntax.core.

Methods
Reader Method: lexer-error-token ((condition lexer-error))
Source

condition.lisp.

Target Slot

token.

Generic Reader: macro-definition-name (object)
Package

with-c-syntax.core.

Methods
Reader Method: macro-definition-name ((macro-definition macro-definition))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

name.

Generic Reader: macro-definition-replacement-list (object)
Package

with-c-syntax.core.

Methods
Reader Method: macro-definition-replacement-list ((macro-definition macro-definition))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

replacement-list.

Generic Reader: physical-source-input-stream-newline-gap (object)
Generic Writer: (setf physical-source-input-stream-newline-gap) (object)
Package

with-c-syntax.core.

Methods
Reader Method: physical-source-input-stream-newline-gap ((physical-source-input-stream physical-source-input-stream))
Writer Method: (setf physical-source-input-stream-newline-gap) ((physical-source-input-stream physical-source-input-stream))

Counts deleted newlines, for __LINE__ .

Source

physical-source.lisp.

Target Slot

newline-gap.

Generic Function: pop-include-state (state)
Package

with-c-syntax.core.

Methods
Method: pop-include-state ((state preprocessor-state))
Source

preprocessor.lisp.

Generic Reader: pp-state-file-pathname (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-file-pathname ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

file-pathname.

Generic Writer: (setf pp-state-file-pathname) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-file-pathname) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

file-pathname.

Generic Reader: pp-state-if-section-skip-reason (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-if-section-skip-reason ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

if-section-skip-reason.

Generic Writer: (setf pp-state-if-section-skip-reason) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-if-section-skip-reason) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

if-section-skip-reason.

Generic Reader: pp-state-if-section-stack (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-if-section-stack ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

if-section-stack.

Generic Writer: (setf pp-state-if-section-stack) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-if-section-stack) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

if-section-stack.

Generic Reader: pp-state-include-stack (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-include-stack ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

include-stack.

Generic Writer: (setf pp-state-include-stack) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-include-stack) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

include-stack.

Generic Reader: pp-state-line-number (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-line-number ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

line-number.

Generic Writer: (setf pp-state-line-number) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-line-number) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

line-number.

Generic Reader: pp-state-macro-alist (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-macro-alist ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

macro-alist.

Generic Writer: (setf pp-state-macro-alist) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-macro-alist) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

macro-alist.

Generic Reader: pp-state-result-list (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-result-list ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

result-list.

Generic Writer: (setf pp-state-result-list) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-result-list) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

result-list.

Generic Reader: pp-state-token-list (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-token-list ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

token-list.

Generic Writer: (setf pp-state-token-list) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-token-list) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

token-list.

Generic Reader: pp-state-tokens-in-line (object)
Package

with-c-syntax.core.

Methods
Reader Method: pp-state-tokens-in-line ((preprocessor-state preprocessor-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

tokens-in-line.

Generic Writer: (setf pp-state-tokens-in-line) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf pp-state-tokens-in-line) ((preprocessor-state preprocessor-state))

automatically generated writer method

Source

preprocessor.lisp.

Target Slot

tokens-in-line.

Generic Function: process-preprocessing-directive (directive-symbol token-list state)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Methods
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|pragma|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|error|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|line|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|undef|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|define|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|include|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|endif|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|else|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|elif|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|ifndef|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|ifdef|)) directive-token-list state)
Method: process-preprocessing-directive ((directive-symbol (eql with-c-syntax.preprocessor-directive:|if|)) directive-token-list state)
Generic Reader: pseudo-pointer-error-offset (condition)
Package

with-c-syntax.core.

Methods
Reader Method: pseudo-pointer-error-offset ((condition pseudo-pointer-error))
Source

condition.lisp.

Target Slot

offset.

Generic Reader: pseudo-pointer-error-pointee (condition)
Package

with-c-syntax.core.

Methods
Reader Method: pseudo-pointer-error-pointee ((condition pseudo-pointer-error))
Source

condition.lisp.

Target Slot

pointee.

Generic Reader: pseudo-pointer-error-pointer (condition)
Package

with-c-syntax.core.

Methods
Reader Method: pseudo-pointer-error-pointer ((condition pseudo-pointer-error))
Source

condition.lisp.

Target Slot

pointer.

Generic Function: push-include-state (state)
Package

with-c-syntax.core.

Methods
Method: push-include-state ((state preprocessor-state))
Source

preprocessor.lisp.

Generic Reader: saved-include-state-if-section-stack (object)
Package

with-c-syntax.core.

Methods
Reader Method: saved-include-state-if-section-stack ((saved-include-state saved-include-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

if-section-stack.

Generic Reader: saved-include-state-package (object)
Package

with-c-syntax.core.

Methods
Reader Method: saved-include-state-package ((saved-include-state saved-include-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

package.

Generic Reader: saved-include-state-readtable (object)
Package

with-c-syntax.core.

Methods
Reader Method: saved-include-state-readtable ((saved-include-state saved-include-state))

automatically generated reader method

Source

preprocessor.lisp.

Target Slot

readtable.

Generic Function: stringification-separator-required-p (prev-token)
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Methods
Method: stringification-separator-required-p ((prev-token (eql with-c-syntax.core:+whitespace-marker+)))
Method: stringification-separator-required-p ((prev-token (eql with-c-syntax.core:+newline-marker+)))
Method: stringification-separator-required-p ((prev-token string))
Method: stringification-separator-required-p ((prev-token character))
Method: stringification-separator-required-p ((prev-token preprocessing-number))
Method: stringification-separator-required-p ((prev-token symbol))
Generic Reader: struct-member-index-table (object)
Package

with-c-syntax.core.

Methods
Reader Method: struct-member-index-table ((struct struct))

automatically generated reader method

Source

struct.lisp.

Target Slot

member-index-table.

Generic Reader: struct-member-vector (object)
Package

with-c-syntax.core.

Methods
Reader Method: struct-member-vector ((struct struct))

automatically generated reader method

Source

struct.lisp.

Target Slot

member-vector.

Generic Writer: (setf struct-member-vector) (object)
Package

with-c-syntax.core.

Methods
Writer Method: (setf struct-member-vector) ((struct struct))

automatically generated writer method

Source

struct.lisp.

Target Slot

member-vector.

Generic Function: translation-early-phase (cp-stream)
Package

with-c-syntax.core.

Methods
Method: translation-early-phase ((cp-stream physical-source-input-stream))

Do translation phase 1 and 2, returns a character.

Source

physical-source.lisp.

Generic Reader: with-c-syntax-style-warning-message (condition)
Package

with-c-syntax.core.

Methods
Reader Method: with-c-syntax-style-warning-message ((condition with-c-syntax-style-warning))
Source

condition.lisp.

Target Slot

message.


6.2.6 Conditions

Condition: compile-error

Used at compiling with-c-syntax forms.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

with-c-syntax-error.

Condition: incompleted-macro-arguments-error
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Direct superclasses

preprocess-error.

Direct slots
Slot: token-list
Initargs

:token-list

Condition: lexer-error

Used in the lexer.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

with-c-syntax-error.

Direct methods

lexer-error-token.

Direct slots
Slot: token
Initargs

:token

Readers

lexer-error-token.

Writers

This slot is read-only.

Condition: preprocess-error

Used in the preprocessor.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

with-c-syntax-error.

Direct subclasses
Condition: preprocess-if-expression-parse-error

Used when an error occurred at the parser.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

preprocess-error.

Direct slots
Slot: yacc-error
Initargs

:yacc-error

Condition: preprocess-include-file-error

Used when an error occurred at the parser.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses
Condition: pseudo-pointer-dangling-error

Used when trying to use a dangling pointer.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

pseudo-pointer-error.

Condition: pseudo-pointer-error

Used at using pseudo-pointers.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

runtime-error.

Direct subclasses
Direct methods
Direct slots
Slot: pointer
Initargs

:pointer

Readers

pseudo-pointer-error-pointer.

Writers

This slot is read-only.

Slot: pointee
Initargs

:pointee

Readers

pseudo-pointer-error-pointee.

Writers

This slot is read-only.

Slot: offset
Initargs

:offset

Readers

pseudo-pointer-error-offset.

Writers

This slot is read-only.

Condition: pseudo-pointer-null-dereference-error

Used when trying to dereference a null pointer.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

pseudo-pointer-error.

Direct slots
Slot: pointer
Initform

(quote nil)

Initargs

:pointer

Slot: pointee
Initform

(quote nil)

Initargs

:pointee

Slot: offset
Initform

(quote 0)

Initargs

:offset

Condition: pseudo-pointer-type-error

Used when trying to make a pointer to a un-pointable object.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

pseudo-pointer-error.

Condition: pseudo-pointer-write-error

Used when trying to write into a non-writable pointer.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

pseudo-pointer-error.

Condition: runtime-error

Used at evaluating with-c-syntax forms.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

with-c-syntax-error.

Direct subclasses

pseudo-pointer-error.

Condition: with-c-syntax-parse-error

Used when an error occurred at the parser.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

with-c-syntax-error.

Direct slots
Slot: yacc-error
Initargs

:yacc-error

Condition: with-c-syntax-reader-error

Used in the with-c-syntax reader. Not for the installer of the with-c-syntax reader.

Package

with-c-syntax.core.

Source

condition.lisp.

Direct superclasses

6.2.7 Structures

Structure: decl-specs

Represents ’decl-specs’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct subclasses

spec-qualifier-list.

Direct methods

make-load-form.

Direct slots
Slot: type-spec
Readers

decl-specs-type-spec.

Writers

(setf decl-specs-type-spec).

Slot: storage-class
Readers

decl-specs-storage-class.

Writers

(setf decl-specs-storage-class).

Slot: qualifier
Readers

decl-specs-qualifier.

Writers

(setf decl-specs-qualifier).

Slot: lisp-type
Initform

t

Readers

decl-specs-lisp-type.

Writers

(setf decl-specs-lisp-type).

Slot: tag
Readers

decl-specs-tag.

Writers

(setf decl-specs-tag).

Slot: typedef-init-decl
Readers

decl-specs-typedef-init-decl.

Writers

(setf decl-specs-typedef-init-decl).

Slot: enum-bindings
Readers

decl-specs-enum-bindings.

Writers

(setf decl-specs-enum-bindings).

Slot: struct-spec
Readers

decl-specs-struct-spec.

Writers

(setf decl-specs-struct-spec).

Structure: enum-spec

Represents ’enum-spec’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct methods

make-load-form.

Direct slots
Slot: id
Readers

enum-spec-id.

Writers

(setf enum-spec-id).

Slot: enumerator-list
Readers

enum-spec-enumerator-list.

Writers

(setf enum-spec-enumerator-list).

Structure: enumerator

Represents ’enumerator’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

init-declarator.

Direct methods

make-load-form.

Structure: function-definition

Represents a function definition.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: func-name
Readers

function-definition-func-name.

Writers

(setf function-definition-func-name).

Slot: storage-class
Readers

function-definition-storage-class.

Writers

(setf function-definition-storage-class).

Slot: func-args
Readers

function-definition-func-args.

Writers

(setf function-definition-func-args).

Slot: func-body
Readers

function-definition-func-body.

Writers

(setf function-definition-func-body).

Slot: lisp-type
Readers

function-definition-lisp-type.

Writers

(setf function-definition-lisp-type).

Structure: init-declarator

Represents ’init-declarator’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct subclasses
Direct methods

make-load-form.

Direct slots
Slot: declarator
Readers

init-declarator-declarator.

Writers

(setf init-declarator-declarator).

Slot: initializer
Readers

init-declarator-initializer.

Writers

(setf init-declarator-initializer).

Slot: lisp-name
Readers

init-declarator-lisp-name.

Writers

(setf init-declarator-lisp-name).

Slot: lisp-initform
Readers

init-declarator-lisp-initform.

Writers

(setf init-declarator-lisp-initform).

Slot: lisp-type
Readers

init-declarator-lisp-type.

Writers

(setf init-declarator-lisp-type).

Slot: function-pointer-p
Readers

init-declarator-function-pointer-p.

Writers

(setf init-declarator-function-pointer-p).

Structure: lisp-type-declaration-table

Used for generating ’(declare type ...)’ from C declarators.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: table
Initform

(make-hash-table :test (quote equal))

Readers

lisp-type-declaration-table-table.

Writers

(setf lisp-type-declaration-table-table).

Structure: param-decl

Represents ’param-decl’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct methods

make-load-form.

Direct slots
Slot: decl-specs
Readers

param-decl-decl-specs.

Writers

(setf param-decl-decl-specs).

Slot: init-declarator
Readers

param-decl-init-declarator.

Writers

(setf param-decl-init-declarator).

Structure: pp-macro-argument
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: token-list
Readers

pp-macro-argument-token-list.

Writers

(setf pp-macro-argument-token-list).

Slot: token-list-expansion
Readers

pp-macro-argument-token-list-expansion.

Writers

(setf pp-macro-argument-token-list-expansion).

Slot: macro-alist
Readers

pp-macro-argument-macro-alist.

Writers

(setf pp-macro-argument-macro-alist).

Structure: pseudo-pointer-to-place

A pseudo-pointer internal type referring a single place, using ‘lambda’.

Package

with-c-syntax.core.

Source

pseudo-pointer.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: lambda
Package

common-lisp.

Readers

pseudo-pointer-to-place-lambda.

Writers

(setf pseudo-pointer-to-place-lambda).

Structure: spec-qualifier-list

Represents ’spec-qualifier-list’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

decl-specs.

Direct methods

make-load-form.

Structure: stat

Represents statements in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: code
Readers

stat-code.

Writers

(setf stat-code).

Slot: declarations
Readers

stat-declarations.

Writers

(setf stat-declarations).

Slot: break-statements
Readers

stat-break-statements.

Writers

(setf stat-break-statements).

Slot: continue-statements
Readers

stat-continue-statements.

Writers

(setf stat-continue-statements).

Slot: case-label-list
Readers

stat-case-label-list.

Writers

(setf stat-case-label-list).

Structure: struct-declarator

Represents ’struct-declarator’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

init-declarator.

Direct methods

make-load-form.

Direct slots
Slot: bits
Readers

struct-declarator-bits.

Writers

(setf struct-declarator-bits).

Structure: struct-or-union-spec

Represents ’struct-or-union-spec’ in C syntax BNF.

Package

with-c-syntax.core.

Source

compiler.lisp.

Direct superclasses

structure-object.

Direct methods

make-load-form.

Direct slots
Slot: type
Package

common-lisp.

Readers

struct-or-union-spec-type.

Writers

(setf struct-or-union-spec-type).

Slot: id
Readers

struct-or-union-spec-id.

Writers

(setf struct-or-union-spec-id).

Slot: struct-decl-list
Readers

struct-or-union-spec-struct-decl-list.

Writers

(setf struct-or-union-spec-struct-decl-list).

Structure: struct-spec

Represents a struct/union specification.

Package

with-c-syntax.core.

Source

struct.lisp.

Direct superclasses

structure-object.

Direct methods

make-load-form.

Direct slots
Slot: struct-name
Readers

struct-spec-struct-name.

Writers

(setf struct-spec-struct-name).

Slot: union-p
Readers

struct-spec-union-p.

Writers

(setf struct-spec-union-p).

Slot: member-defs
Readers

struct-spec-member-defs.

Writers

(setf struct-spec-member-defs).

Slot: defined-in-this-unit
Readers

struct-spec-defined-in-this-unit.

Writers

(setf struct-spec-defined-in-this-unit).

Structure: wcs-fexcept
Package

with-c-syntax.libc-implementation.

Source

fenv.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: flags
Type

fixnum

Initform

0

Readers

wcs-fexcept-flags.

Writers

(setf wcs-fexcept-flags).


6.2.8 Classes

Class: function-like-macro
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Direct superclasses

macro-definition.

Direct methods
Direct slots
Slot: identifier-list
Initargs

:identifier-list

Readers

function-like-macro-identifier-list.

Writers

This slot is read-only.

Slot: variadicp
Initargs

:variadicp

Readers

function-like-macro-variadicp.

Writers

This slot is read-only.

Class: if-section
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Direct methods

print-object.

Direct slots
Slot: group-conditions
Type

vector

Initform

(make-array 1 :fill-pointer 0 :adjustable t)

Class: macro-definition
Package

with-c-syntax.core.

Source

preprocessor.lisp.

Direct subclasses
Direct methods
Direct slots
Slot: name
Initargs

:name

Readers

macro-definition-name.

Writers

This slot is read-only.

Slot: replacement-list
Initargs

:replacement-list

Readers

macro-definition-replacement-list.

Writers

This slot is read-only.

Class: object-like-macro
Package

with-c-syntax.core.

Source