- Concatenative programming language
-
Programming paradigms - Agent-oriented
- Automata-based
- Component-based
- Concatenative
- Concurrent computing
- Relativistic programming
- Data-driven
- Declarative (contrast: Imperative)
- Constraint
- Dataflow
- Cell-oriented (spreadsheets)
- Reactive
- Logic
- Abductive logic
- Answer set
- Constraint logic
- Functional logic
- Inductive logic
- Event-driven
- Expression-oriented
- Feature-oriented
- Function-level (contrast: Value-level)
- Functional
- Generic
- Imperative (contrast: Declarative)
- Language-oriented
- Metaprogramming
- Non-structured (contrast: Structured)
- Nondeterministic
- Parallel computing
- Programming in the large / small
- Semantic
- Structured (contrast: Non-structured)
- Modular (contrast: Monolithic)
- Object-oriented
- Recursive
- Value-level (contrast: Function-level)
A concatenative programming language is a point-free programming language in which all expressions denote functions and the juxtaposition of expressions denotes function composition.[1] The combination of a compositional semantics with a syntax that mirrors such a semantics makes concatenative languages highly amenable to algebraic manipulation.[2]
Much of the original work on concatenative language theory was carried out by Manfred von Thun.
Contents
Properties
The properties of concatenative languages are the result of their compositional syntax and semantics:
- The reduction of any expression is the simplification of one function to another function; it is never necessary to deal with the application of functions to objects.[3]
- Any subexpression can be replaced with a name that represents the same subexpression. This is referred to in the concatenative community as factoring and is used extensively to simplify programs into smaller parts.
- The syntax and semantics of concatenative languages form the algebraic structure of a monoid.[4]
- Concatenative languages can be made well-suited to an implementation inspired by linear logic where no garbage is ever generated.[5]
Implementations
The first concatenative programming language was Forth, although Joy was the first language to call itself concatenative. Other concatenative languages are Cat, Enchilada, Factor, Onyx, PostScript, RPL, Stappl, Trith and XY.
Most existing concatenative languages are stack-based; this is not a requirement and other models have been proposed.[6][7] Concatenative languages are currently used for embedded, desktop, and web programming, as target languages, and for research purposes.
Most concatenative languages are dynamically typed. One exception is the statically typed Cat language.[8]
See also
References
- ^ Christopher Diggins: What is a concatenative language
- ^ Rationale for Joy, a functional language
- ^ Joy compared with other functional languages.
- ^ von Thun, Manfred: Mathematical foundations of Joy
- ^ Henry Baker: Linear Logic and Permutation Stacks — The Forth Shall Be First
- ^ The Concatenative Language XY
- ^ The Enchilada Programming Language
- ^ Cat Specification
External links
- concatenative.org: A wiki about concatenative languages
- Staapl: Forth on Scheme for Embedded Controllers
- The Enchilada Programming Language
- The Concatenative Language XY
Categories:- Concatenative programming languages
Wikimedia Foundation. 2010.