HtDP: Languages as Libraries
1 HtDP Beginning Student
The lang/htdp-beginner module provides the Beginning Student language for How to Design Programs; see Beginning Student.
2 HtDP Beginning Student with Abbreviations
The lang/htdp-beginner-abbr module provides the Beginning Student with Abbreviations language for How to Design Programs; see Beginning Student with List Abbreviations.
3 HtDP Intermediate Student
The lang/htdp-intermediate module provides the Intermediate Student language for How to Design Programs; see Intermediate Student.
4 HtDP Intermediate Student with Lambda
The lang/htdp-intermediate-lambda module provides the Intermediate Student with Lambda language for How to Design Programs; see Intermediate Student with Lambda.
5 HtDP Advanced Student
The lang/htdp-advanced module provides the Advanced Student language for How to Design Programs; see Advanced Student.
6 Pretty Big Text (Legacy Language)
The lang/plt-pretty-big-text module is similar to the HtDP Advanced Student language, but with more of PLT Scheme’s libraries. It provides the bindings of mzscheme, mzlib/etc, mzlib/file, mzlib/list, mzlib/class, mzlib/unit, mzlib/include, mzlib/defmacro, mzlib/pretty, mzlib/string, mzlib/thread, mzlib/math, mzlib/match, mzlib/shared, and lang/posn.
7 Pretty Big (Legacy Language)
The lang/plt-pretty-big module extends lang/plt-pretty-big-text with scheme/gui/base and lang/imageeq. This language corresponds to the Pretty Big Scheme legacy language in DrScheme.
8 posns in HtDP Languages
| |||||
x : any/c | |||||
y : any/c |
The posn structure type that is also provided by lang/htdp-beginner.
9 Image Equality in HtDP Languages
i1 : (is-a?/c image-snip%) |
i2 : (is-a?/c image-snip%) |
The image-comparison operator that is also provided by lang/htdp-beginner.
10 Higher-order Primitives in HtDP Beginner
The lang/prim module defines two syntactic forms for use by the implementors of teachpacks, which the teachpack is to be used with the How to Design Programs Beginner Student languages. In Beginner Student, primitive names (for built-in procedures) are distinguished from other types of expressions, so that they can be syntactically restricted to application positions.
(define-higher-order-primitive id proc-id (arg )) |
Defines id to be a primitive operator whose implementation is proc-id. Normally, id is exported from the teachpack and proc-id is not.
For each non-procedure argument, the corresponding arg should be an underscore. For each procedure argument, the corresponding arg should be the usual name of the procedure.
Examples: |
(define-higher-order-primitive convert-gui convert-gui/proc (f2c)) |
(provide-higher-order-primitive id (arg )) |
Like define-higher-order-primitive, but the function id is exported as the primitive operator named id.
(define-primitive id proc-id) |
Defines id to be a primitive operator whose implementation is proc-id, and that takes no procedures as arguments. Normally, id is exported from the teachpack and proc-id is not.
(provide-primitive id) |
Like define-primitive, but the function id is exported as the primitive operator named id.
(provide-primitives id ) |
Multiple-identifier version of provide-primitive.