From bb0f8e12aa8277f9823d11935007ca90a5a6a670 Mon Sep 17 00:00:00 2001 From: Marcel Otto Date: Thu, 1 Mar 2018 13:16:31 +0100 Subject: [PATCH] Fix typos and RDF.Serialization.Decoder callback spec --- CHANGELOG.md | 4 ++-- lib/rdf/serialization/decoder.ex | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 288fdb6..809e25c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,10 +14,10 @@ This project adheres to [Semantic Versioning](http://semver.org/) and ### Fixed -- Fix `unescape_map` in `parse_helper` for Elixir 1.6 ([@ajkeys](https://github.com/ajkeys) +- Fix `unescape_map` in `parse_helper` for Elixir 1.6 ([@ajkeys](https://github.com/ajkeys)) -[Compare v0.3.0...HEAD](https://github.com/marcelotto/rdf-ex/compare/v0.3.0...v0.3.1) +[Compare v0.3.0...v0.3.1](https://github.com/marcelotto/rdf-ex/compare/v0.3.0...v0.3.1) diff --git a/lib/rdf/serialization/decoder.ex b/lib/rdf/serialization/decoder.ex index 401b310..3f68a56 100644 --- a/lib/rdf/serialization/decoder.ex +++ b/lib/rdf/serialization/decoder.ex @@ -1,6 +1,6 @@ defmodule RDF.Serialization.Decoder do @moduledoc """ - A behaviour for decoder of strings encoded in a specific `RDF.Serialization` format. + A behaviour for decoders of strings encoded in a specific `RDF.Serialization` format. """ @@ -10,7 +10,8 @@ defmodule RDF.Serialization.Decoder do It returns an `{:ok, data}` tuple, with `data` being the deserialized graph or dataset, or `{:error, reason}` if an error occurs. """ - @callback decode(String.t, keyword) :: keyword(RDF.Graph.t | RDF.Dataset.t) + @callback decode(String.t, keyword) :: {:ok, RDF.Graph.t | RDF.Dataset.t} | + {:error, any} @doc """ Decodes a serialized `RDF.Graph` or `RDF.Dataset` from the given string.