summaryrefslogtreecommitdiff
path: root/src/rebar_prv_update.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/rebar_prv_update.erl')
-rw-r--r--src/rebar_prv_update.erl10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/rebar_prv_update.erl b/src/rebar_prv_update.erl
index 64fe65e..049e78c 100644
--- a/src/rebar_prv_update.erl
+++ b/src/rebar_prv_update.erl
@@ -15,6 +15,15 @@
-define(PROVIDER, update).
-define(DEPS, []).
+%% Ignore warning of digraph opaque type when running dialyzer
+-dialyzer({no_opaque, do/1}).
+-dialyzer({no_opaque, write_registry/3}).
+
+%% Ignoring the opaque type warning won't stop dialyzer from warning of
+%% no return for functions that had the opaque type warnings
+-dialyzer({no_return, do/1}).
+-dialyzer({no_return, write_registry/3}).
+
%% ===================================================================
%% Public API
%% ===================================================================
@@ -63,6 +72,7 @@ do(State) ->
format_error(package_index_write) ->
"Failed to write package index.".
+-spec write_registry(rebar_dict(), {digraph, ets:tid(), ets:tid(), ets:tid(), any()}, rebar_state:t()) -> ok | {error, atom()}.
write_registry(Dict, {digraph, Edges, Vertices, Neighbors, _}, State) ->
RegistryDir = rebar_packages:package_dir(State),
filelib:ensure_dir(filename:join(RegistryDir, "dummy")),