Use empty tuple as unit type, for all side-effects.
[hope.git] / src / hope_kv_list.erl
index c12f3b4..6e3442d 100644 (file)
@@ -105,11 +105,12 @@ pop(T1, K) ->
     ;   false               -> {none     , T1}
     end.
 
--spec iter(t(K, V), fun((K, V) -> ok)) ->
-    ok.
+-spec iter(t(K, V), fun((K, V) -> any())) ->
+    {}.
 iter(T, F1) ->
     F2 = lift_map(F1),
-    lists:foreach(F2, T).
+    ok = lists:foreach(F2, T),
+    {}.
 
 -spec map(t(K, V), fun((K, V) -> V)) ->
     t(K, V).
This page took 0.026913 seconds and 4 git commands to generate.