   (emit-map-start [em size])
   (emit-map-end [em])
   (emit-quoted [em o cache])
-  (flush-writer [em])
+  (flush-writer [em stm])
   (prefers-strings [em]))
 
 (def JSON_INT_MAX (Math/pow 2 53))

        (set! *handlers* (assoc *handlers* t h))
        h))))

(deftype Writer [marshaler opts])

(defprotocol Writerable
  (make-writer [_ type opts]))

     (case type
       :json (.createGenerator (JsonFactory.) stm)
       :msgpack (.createPacker (MessagePack.) stm))
     stm
     opts))
  java.io.Writer
  (make-writer [^java.io.Writer w type opts]
