Using your example--very helpful, BTW--I simplified it a bit more:
user=> (def x 10)
#'user/x
user=> (def y #'x)
#'user/y
user=> y
#'user/x
user=> @y
10
user=> (def x (fn [me] (println "Welcome" me)))
#'user/x
user=> (y "hello")
Welcome hello
nil
user=> (@y "yikes")
Welcome yikes
nil
What I come away with from this is a better understanding that when I
refer to "y" in the above code, it's going to return a symbol. When I
place this value in the first slot of a list, the symbol will act in
its role as a function. Otherwise, if "y" is holding a reference to a
symbol that is a value, like 10, then I need to dereference it to use
it.
user=> (def x 15)
#'user/x
user=> @y
15
user=> (y)
java.lang.ClassCastException: java.lang.Integer cannot be cast to
clojure.lang.IFn (NO_SOURCE_FILE:0)
I believe that ClassCastException makes more sense to me now. Like
you said, pointers. I suppose my brain just doesn't want to accept
pointers in the JVM!