3 ms·
Does kebab-case even work, generally speaking? Does it not clash with the subtraction operator?
by Biganon 4y ago
Does kebab-case even work, generally speaking? Does it not clash with the subtraction operator?
- grose 4y agoKebab-case is used in languages that don't have subtraction operators in arbitrary locations (in the sense of C), like Lisp and CSS.
- ogoffart 4y agoThe language I designed for Slint [https://github.com/slint-ui/slint https://github.com/slint-ui/slint] uses kebab-case, so it mandates spaces around the minus sign. (If the lookup for `foo-bar` fails, it tries with `foo` and if that succeeds, the error message suggest the use of spaces)
- deleted 4y ago[deleted]
- vvillena 4y agoLike most esoteric language features in existence, Raku allows for it. Probably easier to support, as variables are prefixed with sigils.
- lizmat 4y agoThe rule for kebab-case (regardless of whether or not it has a sigil) in Raku is: - each part of the identifier must start with an alpha character - cannot end with - So, "foo-bar" would be legal, "foo-" would not, "foo-4" would be considered "foo" - 4. If you want to substract two sigilless identifiers, you *must* have whitespace between them. So "foo - bar" instead of "foo-bar".