Meaning of Symbolic Pattern Matching Languages

By Xah Lee. Date: .

In symbolic pattern matching ruled based lang such as Wolfram Language, there is this property, for 20 years, from 1990s to 2000s, i didn't know how to describe it. Now i know. When i first heard of “denotational semantics”, i thought that's it, but its not.

In Java for example, they talk about serialization. That is, some “object” have a output form that can be read back, example: JSON from JavaScript. [see JavaScript: JSON] In symbolic pattern matching lang such as Mathematica, basically the entire source code is “serialized”. That IS the ESSENTIAL requirement for symbolic pattern matching.

Note that symbolic pattern matching is not the same as those pattern matching in ocaml or haskell. These are not symbolic. They are value and type based pattern matching. They match a intermediate representation of the language's computational model. Or, rather, they match internal binary blobs. Lisp macro, is sort of symbolic pattern matching, but a extremely limited one, in the sense of just matching order of arguments, no pattern to speak of.

In other words, in symbolic pattern matching lang, there is (basically) no concept in the lang that produces certain “object blob” or “internal thing”. Everything, is laid out as text, like JSON.

Another way to say is, in symbolic pattern matching lang, the language is just a collection of literal expressions. And the computing model of such a language is transforming these textual expressions. There is no concept intermediate representation or (internal) “object”, as few as possible. Or, we say, that such concept is not essential in the programing language's computational model.