Details
-
Type:
Defect
-
Status:
Closed
-
Priority:
Major
-
Resolution: Completed
-
Affects Version/s: None
-
Fix Version/s: Release 1.3
-
Component/s: None
-
Labels:None
-
Approval:Ok
Description
munge is overeager in converting $ to DOLLARSIGN, since $ is a valid
character in Java identifiers:
user> (filter #(Character/isJavaIdentifierPart %) (keys clojure.lang.Compiler/CHAR_MAP)) (\$)
On a related point, ' (single quote) is not admissible in Java
identifiers, but it is not munged on master:
user=> (Character/isJavaIdentifierPart \') false user=> (munge "'") "'"
This leads to e.g.
user=> *' #<core$_STAR_' clojure.core$_STAR_'@5adf48c4>
(note the ' after STAR).
Originally reported on the Dev list.
See also this thread on the (regular) Clojure ggroup.
The attached patch applies cleanly against current master.