2 ms·
Sure, Lisps allow many more characters in the identifiers, including all traditional operators (makes sense, since the "operators" are just functions and they h
by klibertp 8y ago
Sure, Lisps allow many more characters in the identifiers, including all traditional operators (makes sense, since the "operators" are just functions and they had to be defined somehow in the first place...) You get functions named like add-message! create-response/text bytes->string/utf-8 and so on. Kebab case refers to identifiers with words separated with minus sign, like some-class-member-doing-something etc. Some infix languages borrowed this, like Dylan and LiveScript, among others.
- Jach 8y agoCommon Lisp actually lets you use any string for an identifier if you wrap it in pipes, though you have to be a bit careful of casing in that case. Still for so many characters on the keyboard it's not needed to wrap which is so convenient as you illustrate. (let ((|hello world| 3) (|HELLO world| 4) (|こんにちは (jp)| 5) (|pi\|pe| 'piped) (|newlines work too| 6)) (list |hello world| |HELLO world| |こんにちは (jp)| |pi\|pe| |newlines work too|)) ; --> (3 4 5 PIPED 6)