Skip to content

Commit

Permalink
resolve lancepantz#2 reflection warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
edbond committed Jun 21, 2013
1 parent 2dc440a commit 4ead227
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/clj_yaml/core.clj
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
(defn make-yaml
[& {:keys [dumper-options]}]
(if dumper-options
(Yaml. (apply make-dumper-options
(mapcat (juxt key val)
dumper-options)))
(Yaml. ^DumperOptions (apply make-dumper-options
(mapcat (juxt key val)
dumper-options)))
(Yaml.)))

(defprotocol YAMLCodec
Expand Down Expand Up @@ -67,12 +67,12 @@
(decode [data] data))

(defn generate-string [data & opts]
(.dump (apply make-yaml opts)
(encode data)))
(.dump ^Yaml (apply make-yaml opts)
^Object (encode data)))

(defn parse-string
([string keywordize]
(binding [*keywordize* keywordize]
(parse-string string)))
([string]
(decode (.load (make-yaml) string))))
(decode (.load ^Yaml (make-yaml) ^String string))))

0 comments on commit 4ead227

Please sign in to comment.