Email or username:

Password:

Forgot your password?
Devine Lu Linvega

A concatenative language differs from the functional programming language paradigm where terms correspond to values (including functions) and the fundamental operation is function application. In the Lambda calculus for example all terms correspond to values, function application, or function abstraction. However, in a catlang all terms correspond to functions on a tuple, or the composition of functions (which yields a new function, so is really a function).

web.archive.org/web/2020092520

6 comments
Your friendly 'net denizen

@neauoire Once I saw the link out to Dr. Dobbs, I was wondering whether the author would be Christopher Diggins. :)

Looks like he's still doing interesting things around languages:

cdiggins.github.io/blog/linear

github.com/cdiggins

WimⓂ️

@neauoire So a catlang is a constrained functional language.

Devine Lu Linvega

@wim_v12e it's kind of a wibbly wobbly category, but yeah.

A concatenative language is completely associative: you can group words within it anyhow you'd like, and maintain the same semantics. A pure functional language is referentially transparent: if two complete expressions have the same semantics, they can be interchanged without changing the program semantics. The functional language, however, requires "complete expressions"; the concatenative language doesn't.

wiki.xxiivv.com/site/concatena

@wim_v12e it's kind of a wibbly wobbly category, but yeah.

A concatenative language is completely associative: you can group words within it anyhow you'd like, and maintain the same semantics. A pure functional language is referentially transparent: if two complete expressions have the same semantics, they can be interchanged without changing the program semantics. The functional language, however, requires "complete expressions"; the concatenative language doesn't.

WimⓂ️

@neauoire What does it mean to have "complete expressions"? Referential transparency refers to the names. If something is not named in an expression, it does not affect referential transparency.
Can you give an example of an expression that is incomplete, but is acceptable for in concatenative language?

Devine Lu Linvega

@wim_v12e like the difference between a lambda and a clojure, or from the tacit point of view where you don't pass assignment and how returning multiple values at once is done.

`(+ x y)`, versus `+`

WimⓂ️

@neauoire By my understanding,
`+` is a complete expression (it's a function), as is `(+ x y)` (an applied function; there is not enough context to say that the bindings are defined but that is not the same as incomplete).
Closures are functions (named or not) that capture some bindings from their outer scope.
Returning multiple values is valid in a functional language too.
I don't understand where the notion of (in)completeness fits in.

Go Up