 
 (defn read-number
   [reader initch]
-  (loop [buffer (gstring/StringBuffer. initch)
+  (loop [buffer (gsb/StringBuffer. initch)
          ch (read-char reader)]
-    (if (or (nil? ch) (whitespace? ch) (macro? ch))
+    (if (or (nil? ch) (whitespace? ch) (contains? macros ch))
       (do
         (unread reader ch)
         (match-number (.toString buffer)))

        (with-meta o (merge (meta o) m))
        (throw "Metadata can only be applied to IWithMetas")))))

#_(defn read-token
  [rdr initch]
  (let [sb (gsb/StringBuffer. initch)]
    (loop [ch (read-char rdr)]
      (if (or (nil? ch)
              (whitespace? ch)
              (macro-terminating? ch))
        (do (unread rdr ch) s)
        (recur (.append sb ch))))))

(def macros
  { \" read-string
    \; not-implemented ;; never hit this
    \' not-implemented
    \@ not-implemented
    \^ read-meta
    \` not-implemented
    \~ not-implemented
    \( read-list
    \) read-unmatched-delimiter
    \[ read-vector
    \] read-unmatched-delimiter
    \{ read-map
    \} read-unmatched-delimiter
    \\ read-char
    \% not-implemented
    \# read-dispatch
    })

(def dispatch-macros
  {"{" read-set})

                       (unread next-ch)
                       next-ch)))))

(declare read macros dispatch-macros)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; read helpers
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(defn macro-terminating? [ch]
  (and (not= ch "#") (not= ch "\'") (contains? macros ch)))

(defn read-token
  [rdr initch]
  (loop [sb (gsb/StringBuffer. initch)
         ch (read-char rdr)]
    (if (or (nil? ch)
            (whitespace? ch)
            (macro-terminating? ch))
      (do (unread rdr ch) (.toString gsb))
      (recur (do (.append sb ch) sb) (read-char rdr)))))

(defn- skip-line
  "Advances the reader to the end of a line. Returns the reader"
