4 ms·
We independently reinvented an adaptation of this algorithm for Monte's "simple" quasiliteral, which does simple string interpolation and matching. The code at
by BuuQu9hu 9y ago
We independently reinvented an adaptation of this algorithm for Monte's "simple" quasiliteral, which does simple string interpolation and matching. The code at https://github.com/monte-language/typhon/blob/master/mast/prelude/simple.mt#L68-L121 https://github.com/monte-language/typhon/blob/master/mast/pr... is somewhat similar in appearance and structure to the examples in the post.
def name := "Hackernews"
# greeting == "Hi Hackernews!"
def greeting := `Hi $name!`
# language == "Lojban"
def `@language is awesome` := "Lojban is awesome"
A quirk of our presentation is that adjacent zero-or-more patterns degenerate, with each subsequent pattern matching the empty string. This mirrors the observation in the post that some systems can coalesce adjacent stars without changing the semantics:
# one == "", two == "cool"
def `adjacent @one@two patterns` := "adjacent cool patterns"
- triangleman 9y agohey BuuQu9hu, your comment started out as [dead] for some reason. You may have been inadvertently hellbanned.
- proaralyst 9y ago...hellbanned?
- darklajid 9y agoBeing (silently) hidden so that your posts look okay to you but don't show up for others (unless they have 'show dead' set to on). It's an effective filtering mechanism, but some consider it rather cruel and try to notify posters about it.
- triangleman 9y agoFalse positives suck. There are people coming on here day after day, posting valuable or at least worthy comments, and nobody can see them. They waste their time unknowingly. It is cruel.