728 B
728 B
Project coding style
- Follow the existing Racket style demonstrated in library-factory.rkt.
- Use define primarily for module definitions, class state, and methods.
- Use let and let* for method-local values and keep related operations in the same lexical scope.
- Prefer explicit intermediate names, such as maker-key, when they clarify intent.
- Keep implementations small and direct; avoid unnecessary helper layers.
- Validate each invariant in one appropriate place. Do not duplicate constructor checks in callers or deserializers.
- Use check/c and check/c* from utils.rkt for concise argument validation where validation is needed.
- Preserve the surrounding formatting and naming style when modifying existing code.