make 'symbol' work on keywords and vars

Description

Port this change from Clojure master to ClojureScript: https://github.com/clojure/clojure/commit/d29219f78e51da66daf1c66108ebebb97c68442f

Implementation guidance:

For Vars, there is a var? predicate, and given a Var v, it is possible to obtain its symbol by using (.-sym v).

Likewise, for keywords, there is a keyword? predicate, and given a Keyword k, it is possible to form a symbol using (symbol (.-fqn k)).

Environment

None

Status

Assignee

Mike Fikes

Reporter

Mike Fikes

Labels

Approval

Accepted

Patch

Code and Test

Priority

Blocker
Configure