Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix henshin:apply_rules/2 spec

  • Loading branch information...
commit a2bbcbda8749e80b9ffbe804da95c2d3cba5a156 1 parent dc8362d
@nox nox authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/henshin.erl
View
8 src/henshin.erl
@@ -53,11 +53,11 @@ apply_rules(Forms) ->
end, [], Forms),
lists:flatten(Result).
--spec apply_rules(term(), rules()) ->
- {term(), rules()}.
-apply_rules(Form, Rules) ->
+-spec apply_rules(erl_syntax:syntaxTree(), rules()) ->
+ {erl_syntax:forms(), rules()}.
+apply_rules(Fun, Rules) ->
{Result, {Rules2, Markers}} = erl_syntax_lib:mapfold(
- fun apply_rules_node/2, {Rules, []}, Form),
+ fun apply_rules_node/2, {Rules, []}, Fun),
{[Result | Markers], Rules2}.
-spec apply_rules_node(
Please sign in to comment.
Something went wrong with that request. Please try again.