[HN Gopher] Show HN: Term-Lisp - A Lisp, based on pattern matchi...
___________________________________________________________________
Show HN: Term-Lisp - A Lisp, based on pattern matching and term
rewriting
Author : boris_m
Score : 43 points
Date : 2024-11-06 14:53 UTC (8 hours ago)
(HTM) web link (github.com)
(TXT) w3m dump (github.com)
| BoiledCabbage wrote:
| Term re-writing systems are a really interesting way of looking
| at computation.
|
| It completely abstracts away the concept of a machine, and it's
| simply translation as computation - but equally as powerful.
| simplify wrote:
| Agreed. This reminds me - and I wonder if it could be applied -
| to Computational Type Theory, which relies on a similar concept
| of "reducing" types to their primitive forms, actually taking
| computation into account (something type theories normally do
| not!)
|
| This lecture series goes into how it works:
| https://www.youtube.com/watch?v=LE0SSLizYUI
| llm_trw wrote:
| It's a shame the standard texts are all 20 years old or more
| than way too heavy mathematically.
|
| A little book for term rewriting would be a great new addition.
| entaloneralie wrote:
| Here's a little zine on multiset rewriting(unordered term
| rewriting), John Conway said(about Fractran in The Book of
| Numbers) that it is such a simple paradigm of computation
| that no book is needed to learn it, and it can be taught in
| 10 seconds.
|
| https://wiki.xxiivv.com/site/pocket_rewriting
| BoiledCabbage wrote:
| I'm somewhat surprised there isn't a semi-mainstream
| language for it. It's incredibly simple, with very few core
| concepts yet very powerful.
|
| Similar to LISP in that sense.
| Jtsummers wrote:
| https://www.researchgate.net/publication/243768023_Mathem
| ati...
|
| Mathematica is at least semi-mainstream. Not sure of any
| other examples though.
| entaloneralie wrote:
| Maude is the most famous one that I know of I think.
|
| https://maude.lcc.uma.es/maude-manual/maude-
| manualch1.html#x...
| opminion wrote:
| The foundations of Wolfram Language (Mathematica) are
| about transformations on symbolic expressions, at least
| conceptually.
| lo_zamoyski wrote:
| I would argue that it is more "primordial". After all,
| computation is first and foremost a human activity, generally
| performed using pen and paper, which involves a good deal of
| rewriting (computers were originally people). The machine only
| came later as a way to simulate this human activity. Its
| meaning is entirely contingent on the primordial notion. It
| have no meaning on its own.
| practal wrote:
| Of course term rewriting has a meaning of its own, it is at
| the same time more meaningful and simpler as any other form
| of computation.
| llm_trw wrote:
| This is vastly more pattern matching than term rewriting. In a
| term rewriting system you have no types for a start:
| https://en.wikipedia.org/wiki/Rewriting
| convolvatron wrote:
| is that important here? it looks like semantically types as
| presented are no more than magic constants to match on
| llm_trw wrote:
| Yes, in term rewriting systems the only thing that matters is
| the lexical structure of the "program" you're running on top
| of the transform rules. A simple example of running a TRS is
| a term of a BNF grammar, a less simple one is a symbolically
| expanding a term in a computer algebra system.
| convolvatron wrote:
| ok. sorry, so the issue is not that some of the runtime
| data is being interpreted as types, its that decisions are
| being made based on the data and not solely on the
| structure of the program.
___________________________________________________________________
(page generated 2024-11-06 23:01 UTC)