3 ms·
I wish we could stop making up new languages in 2022 that use unenclosed strings...
by Nullabillity 4y ago
I wish we could stop making up new languages in 2022 that use unenclosed strings...
- User23 4y agoThere are no strings in this language.
- Nullabillity 4y agoThe first example on https://jevko.org/ https://jevko.org/ contains plenty of strings.
- User23 4y agoNo, it contains a tree of text objects, which aren’t strings. Now the language that the Jevko parser is written in will probably store that text tree using strings, but that’s a statement about the parser implementation and not the formally specified Jevko language, which, as I said, has no strings. For example, a Common Lisp hosted Jevko parser implementation might choose to represent Jevko text objects as symbols.
- Nullabillity 4y agoA "text object" is just an overly verbose name for... a string. Which doesn't necessarily have to be called a capital-s String in your chosen language, atoms/symbols are also forms of strings.
- User23 4y agoIf you like confused and muddled understanding of types, why not just insist it’s all bit vectors? Every data type you can name is just a form of bit vector after all.
- gnulinux 4y agoYou're not understanding. These are not strings. These are symbols. Say in python you write `a = b`. Are "a" and "b" strings? No. In these examples what you're referring to as strings are just meant to be symbols like "a" and "b". It just so happens that the implementation uses "String" data type to represent them. Other examples: in XML when you write `<abc></abc>` is "abc" a string? In s-expressions (or lisp) when you write `(if a b)` are "if", "a" and "b" strings?
- Nullabillity 4y agoThat XML snippet isn't really representative though, let's consider `<a b="c">d</a>` instead. Here, `c` and `d` are definitely plain old strings. Likewise, in the Jevko expression `a [b]` I don't see how `b` is not a string.
- gnulinux 4y ago> I don't see how `b` is not a string. Because it isn't. There is no concept of a string. `if [[a] [b]]` is similar to `(if a b)`. So in your example `a [b]` is similar to s-expression `(a b)`. Neither "a" nor "b" are strings here.
- kazinator 4y agoIf b is a symbol, which one is it? Is it interned, or uninterned? Given the Jevko syntax [b b], is that a repetition of the same object, or is that two different symbols that have the same name? Is it like (b b) or (#:b #:b)? Why or why not; based on what documentation? In symbol manipulation, symbols are atoms. Each symbol represents an identity. An identity cannot be fractured into sub-identities. The textual name of a symbol just provides a written notation; all semantics of symbol manipulation concerns itself only with whether two symbols are the same one or a different symbol. For instance the idea that the symbol foo is a prefix of the symbol foobar is invalid. We may only ask whether foo and foobar are the same entity or different. A basic operation in symbol manipulation is semantics-preserving substitution. If Jevko is based on symbols then [a b b] can be replaced by [a c c] without loss of semantics. In fact, all we are doing is changing the name of the b symbol; its identity remains the same. Suppose there is some application built on Jevko in which [a=b b] cannot be replaced by [a=b c] without destroying the semantics; suppose it has to be that in that application, if b is replaced by c, then [a=b b] must turn into [a=c c], in order to preserve a relationship that holds between a=b and b. That application has then destroyed the concept of a Jevko symbol, because a=b isn't functioning like an atom any more. It's functioning like two symbols a= b or possibly three symbols a = b. Thus if a=b is really one symbol, and not a string of three characters, then no legitimate, Jevko-respecting application of Jevko can do anything like this, namely treat a=b as being syntax which codes for two or three atoms. But that's a lie, because Jevko is intended for doing that sort of thing like it's going out of style. For instance, in this code: https://github.com/jevko/jevkodom.js/blob/master/jevkoToHtml.js https://github.com/jevko/jevkodom.js/blob/master/jevkoToHtml... can you explain what mid.endsWith('=')? "attr": "tag" is doing? It sure looks to me like it's asking whether a symbol (i.e. indivisible atom) ends with an equal sign, which is semantic gibberish.