-
-
Notifications
You must be signed in to change notification settings - Fork 17
Closed
Labels
component:basilisp.coreIssue pertaining to basilisp.core namespaceIssue pertaining to basilisp.core namespaceissue-type:bugSomething isn't workingSomething isn't working
Description
Hi,
there appears to be an issue when trying to keywordizing strings containing slashes, such as "abc/xyz". These string don't compare equal to their corresponding namespaced keywords, even though their string representation match.
To reproduce
- Open up the REPL, create a keywordize slashed string, compare it with its counterpart and inspect it, it fails the check
basilisp.user=> (def issuekw (keyword "abc/xyz"))
#'basilisp.user/issuekw
basilisp.user=> issuekw
:abc/xyz
basilisp.user=> (= issuekw :abc/xyz)
false
basilisp.user=> (namespace issuekw)
nil
basilisp.user=> (name issuekw)
"abc/xyz"
In clojure comparison works as expected, comparing equal with their counterparts, internally the string to a namespace and name components
user=> (def issuekw (keyword "abc/xyz"))
#'user/issuekw
user=> issuekw
:abc/xyz
user=> (= issuekw :abc/xyz)
true
user=> (namespace issuekw)
"abc"
user=> (name issuekw)
"xyz"
Thanks
Metadata
Metadata
Assignees
Labels
component:basilisp.coreIssue pertaining to basilisp.core namespaceIssue pertaining to basilisp.core namespaceissue-type:bugSomething isn't workingSomething isn't working