| PROGRAMMING LANGUAGE (in the intensional sense)
|
-> Linguistics:
langue
five components:
|
|
| library
|
|
|
|
| Syntax
| |
specifies the set of program texts
|
|
|
|
(optional)
Type System
| | |
| | static | | dynamic
|
|
infers program terms' types
defines the subset of legal program texts
|
| | |
|
|
Computational Semantics
| |
describes what computations are specified by (legal) program texts
|
|
|
|
^Model of Computation
| |
describes objects, events, relations, types
in runtime software systems
|
| | cf. ontology
|
|
|
| Standard Library
| | |
| language support
| | convenience
| |
-> Linguistics:
lexicon
|
|
|
features
constructs = syntax + typing + semantics
«Since its introduction in Hope [BMS80], the datatype construct
has become a staple of modern functional language design [WAL+89, MTH90, HJW+92, etc.].
Bundling together several lower-level features
- mutally recursive types, variants, and parameterized types
- it offers convenient syntax for common programming styles,
aids type inference, and shortens printed representations of types.
Moreover, it provdes a "hook" by which numerous other features my smoothly be added
[...].»
[DT&ST]
Haruo Hosoya, Bejamin C Pierce, David N Turner: Datatypes and Subtyping; July 24, 1998.
|
| |
| |
|
| untyped
| | typed
| | safe
|
| no type system
| | with type system
| | no untrapped execution errors
|
| |
sem: typed values +/- range-typed lvals
text: typed exprs +/- typed lval-exprs
untyped = typed vals but cannot give a type to vars
(+ cannot give type to parms => funs only arity-typed)
| |
|