Add map typespec for dialyzer This obviously only exists on VMs that support it.
Project: http://git-wip-us.apache.org/repos/asf/couchdb-jiffy/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb-jiffy/commit/e132b633 Tree: http://git-wip-us.apache.org/repos/asf/couchdb-jiffy/tree/e132b633 Diff: http://git-wip-us.apache.org/repos/asf/couchdb-jiffy/diff/e132b633 Branch: refs/heads/master Commit: e132b633f586281cfce7d4f1e71a41c96555e963 Parents: f284a1b Author: Paul J. Davis <[email protected]> Authored: Fri Jul 17 11:59:50 2015 -0500 Committer: Paul J. Davis <[email protected]> Committed: Fri Jul 17 11:59:50 2015 -0500 ---------------------------------------------------------------------- src/jiffy.erl | 4 ++++ 1 file changed, 4 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb-jiffy/blob/e132b633/src/jiffy.erl ---------------------------------------------------------------------- diff --git a/src/jiffy.erl b/src/jiffy.erl index c987997..4ee2a9e 100644 --- a/src/jiffy.erl +++ b/src/jiffy.erl @@ -23,6 +23,10 @@ -type json_number() :: integer() | float(). -type json_object() :: {[{json_string(),json_value()}]}. +-ifndef(JIFFY_NO_MAPS). +-type #{json_string() => json_value()}. +-endif. + -type jiffy_decode_result() :: json_value() | {has_trailer, json_value(), binary()}.
