from Hacker News

Strand Programming Language

by QuinnWilton on 4/26/21, 9:25 PM with 28 comments

  • by skissane on 4/27/21, 5:37 AM

    Their implementation approach is interesting: they have their own custom Forth implementation, with a kernel written in assembly language (ARM, aarch64, x86_64 and ppc64le). Then Strand is written in a mixture of Forth and itself.
  • by simplify on 4/26/21, 11:44 PM

    A sample from their user manual[0]:

        % print even numbers between 1 and 10
    
        main :- count(1).
    
        count(11).
        count(N) :- N =< 10 | even(N), N2 is N + 1, count(N2).
    
        even(N) :- M is N \\ 2, even(M, N).
    
        even(0, N) :- writeln(N).
        even(_, _) :- otherwise | true.
    
    [0] http://www.call-with-current-continuation.org/strand/MANUAL
  • by doublec on 4/27/21, 3:22 AM

    From the same author, and in the same family of languages, is FLENG: http://www.call-with-current-continuation.org/fleng/fleng.ht...

    It lacks Strand's distributed features but includes prolog's unification.

  • by gnufx on 4/27/21, 10:09 AM

    I wasn't involved, but I remember considerable interest in Strand from parallel programming people in the lab about the time it appeared. I don't think that lasted long, but unfortunately I don't remember why it failed (if I knew then).

    SISAL was probably a better bet as a dataflow-ish language, but I don't remember anyone else looking at it, despite Manchester being "just" down the road.

  • by anentropic on 4/27/21, 12:05 PM

    No idea if related in any meaningful way, but https://github.com/rust-lang/chalk/tree/master/chalk-engine/... (a "PROLOG-like logic solver" for the Rust trait system) also makes use of "strands"
  • by chrisjharris on 4/27/21, 3:44 AM

    I find this fascinating, if a bit incomprehensible, but what might an intended use case be?
  • by ADavison2560 on 4/27/21, 7:55 AM

    A good introduction to concurrent logic languages:

    Parlog86 and the dining logicians G. A. Ringwood Communications of the ACM January 1988 https://doi.org/10.1145/35043.35044

    https://dl.acm.org/doi/10.1145/35043.35044

  • by pie_flavor on 4/27/21, 4:39 PM

    From the User's Manual:

        三個和尚沒水喝
    
        (Chinese Proverb)