home.social

#concatenative — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #concatenative, aggregated by home.social.

  1. @go_shrumm So glad to learn from you today about the concept of #parataxis! I've been doing a lot of #Forth programming lately, and this concept seems to create a fresh window into the mysterious richness of #concatenative languages.
    en.wikipedia.org/wiki/Parataxi
    en.wikipedia.org/wiki/Concaten

  2. #HowToThing #029 — One for the #Forth friends: Minimal livecoding playground for animated 2D geometry generation (incl. SVG export) using a Forth-like DSL (domain-specific language) based on thi.ng/pointfree, thi.ng/pointfree-lang and various geometry related operations using thi.ng/geom. A short screen recording is included to demonstrate overall usage. This is a cutdown version of a prototype tool, originally from 2019...

    Even though the language is "Forthy", the underlying thi.ng/pointfree implementation does _not_ use a VM, but instead compiles words to vanilla JavaScript using normal functional composition (or reductions) and each word is passing data & state via a single shared stack context object (with the usual dual data & return stacks and an environment object with var bindings). The language supports quotations, local variables, combinators etc.

    I _highly_ recommend consulting the detailed readme docs for the above packages to familiarize yourself with the basic principles & language features/syntax. If you do have some prior #Forth knowledge, many aspects should feel familiar (apart from the geometry DSL terms)...

    Also worth pointing out that the editor/interpreter in this small example is not super forgiving re: error handling and might easily crash when live coding. The point of this demo is not about providing great UX, but to illustrate how the basic thi.ng/pointfree language infrastructure can be easily extended/adapted/integrated...

    Demo:
    demo.thi.ng/umbrella/pointfree

    Source code:
    github.com/thi-ng/umbrella/tre

    (Note: The source code of the actual language bindings for the geometry operations is not shown here, but available in the `lang.ts` file, linked above...)

    #Forth #Pointfree #Concatenative #Programming #Geometry #Graphics #SVG #GenerativeArt #GenerativeDesign #TypeScript #JavaScript #ThingUmbrella