DennisMitchell / jellylanguage

Jelly is a recreational programming language inspired by J.
MIT License
860 stars 47 forks source link

Add char-pair literals #16

Closed lynn closed 8 years ago

lynn commented 8 years ago

strings eat up all characters in the space-through-tilde ASCII range:

    $ ./jelly eun ⁽HelloṚ
olleH

strings are two characters long:

    $ ./jelly eun ⁾abx5
aaaaabbbbb
lynn commented 8 years ago

Dennis wrote that he intends to work slightly differently from this PR’s implementation:

@Lynn Hm, isn't quite what I had in mind. For example, ‘o' + 128 = ‘ṁ’. Then ⁽HellṁX would pseudo-randomly choose a character from the string Hello.

But then:

Still have to decide whether the unprintable code points should correspond to those ASCII characters (rarely useful except for a handful of them) or use a custom encoding of all Unicode characters.

So this feature will probably have to wait a little.