gilch / hissp

It's Python with a Lissp.
https://gitter.im/hissp-lang/community
Apache License 2.0
364 stars 9 forks source link

Consider munging `-` as `QzH_` instead of `Qz_` #256

Open gilch opened 1 month ago

gilch commented 1 month ago

The munger's short names have gone through several iterations. I think I'm mostly satisfied with the current set. - used to have H (short for "Hyphen-Minus", its Unicode name) as its short name due to a technical limitation that couldn't handle the empty name. I fixed that, but after trying it for a while, I don't find it any easier to read. It is one character shorter, but when I see the Qz, I automatically look for the name following it to give it its meaning, don't find it, and it takes a moment to remember this is the one special case. I still feel pretty strongly that I shouldn't simply munge - to _, as this isn't cleanly reversible and _ can have special meaning in Python, but it does make common macros like if-else ugly for alternate readers that don't use the munger. (So, e.g., ifQzH_else instead of ifQz_else.)

It's especially bad in Hebigo, but it comes bundled with its own versions, and in readerless, but it's ugly regardless, and in practice, one would probably do something like from hissp import munge as m. The EDN Hissps can use hyphens in symbols. If anything, I'd consider avoiding special characters in the bundled macro names, although this would look more verbose and a bit less Lispy.

This change is not happening before the 0.5 release.