4.2.5 Documenting Signatures

► |  | Scribble: The Racket Documentation Tool

1 | Getting Started
2 | @ Syntax
3 | High-Level Scribble API
4 | Scribbling Documentation
5 | Literate Programming
6 | Low-Level Scribble API
7 | Running scribble
| Index

► | 4 | Scribbling Documentation

4.1 | Getting Started with Documentation
4.2 | Manual Forms
4.3 | Racket
4.4 | Evaluation and Examples
4.5 | In-Source Documentation
4.6 | BNF Grammars
4.7 | Compatibility Libraries

▼ | 4.2 | Manual Forms

4.2.1 | Typesetting Code
4.2.2 | Documenting Modules
4.2.3 | Documenting Forms, Functions, Structure Types, and Values
4.2.4 | Documenting Classes and Interfaces
4.2.5 | Documenting Signatures
4.2.6 | Various String Forms
4.2.7 | Links
4.2.8 | Indexing
4.2.9 | Bibliography
4.2.10 | Version History
4.2.11 | Miscellaneous
4.2.12 | Index-Entry Descriptions
4.2.13 | Manual Rendering Style

On this page:

defsignature
defsignature/ splice
signature-desc
sigelem

top contents ← prev up next →

#### 4.2.5 Documenting Signatures🔗ℹ

> syntax (defsignature id (super-id ...) pre-flow ...)

Defines a signature id that extends the super-id signatures. Any elements defined in decoded pre-flows—including forms, procedures, structure types, classes, interfaces, and mixins—are defined as members of the signature instead of direct bindings. These definitions can be referenced through sigelem instead of racket.

The decoded pre-flows inset under the signature declaration in the typeset output, so no new sections, etc. can be started.

> syntax (defsignature/splice id (super-id ...) pre-flow ...)

Like defsignature, but the decoded pre-flows are not typeset under the signature declaration, and new sections, etc. can be started in the pre-flows.

> procedure (signature-desc pre-flow ...) → any/c
> pre-flow : pre-flow?

Produces an opaque value that defsignature recognizes to outdent in the typeset form. This is useful for text describing the signature as a whole to appear right after the signature declaration.

> syntax (sigelem sig-id id)

Typesets the identifier id with a hyperlink to its definition as a member of the signature named by sig-id.
top contents ← prev up next →