ClojureScript

Inconsistencies when calling 'name' on keywords from strings vs literal keywords

Details

  • Type: Defect Defect
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Duplicate
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
  • Environment:
    Clojurescript r2024; Java 1.7.0_25; OSX 10.9

Description

Clojurescript:
1. (keyword "some.name.spaced/keyword")
:some.name.spaced/keyword

2. (name (keyword "some.name.spaced/keyword"))
"some.name.spaced/keyword"

3. (name :some.name.space/keyword)
"keyword"

I'd expect 2 and 3 to return the same string, given 1 returns what looks like the keyword I give to 3.

In contrast to Clojure:
(keyword "some.name.spaced/keyword")
:some.name.spaced/keyword

(name (keyword "some.name.spaced/keyword"))
"keyword"

(name :some.name.space/thing)
"thing"

Activity

Hide
David Nolen added a comment - - edited
Show
David Nolen added a comment - - edited CLJS-660
David Nolen made changes -
Field Original Value New Value
Resolution Duplicate [ 3 ]
Status Open [ 1 ] Resolved [ 5 ]
David Nolen made changes -
Status Resolved [ 5 ] Closed [ 6 ]

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: