Skip to content

Commit

Permalink
erlfmt_ast returns pos as erl_anno:anno() instead of a map
Browse files Browse the repository at this point in the history
Since OTP 24 (commit erlang/otp@f30514e#diff-9f3b412e8fbd809c6473fcd5bee30f63931c7349010640d76316cfcde504e733)
 `erl_syntax:set_pos` started to require a proper `erl_anno:anno()` instead of any term.

`erlfmt_ast` used to just copy the `erlfmt_scan:anno()` map from the input to
`syntaxTree()`, but that does not work any more. Now it is converted to an
`erl_anno:anno()` to make dialyzer happy. (There is a bit of cheating with
`end_location` in the hope that it will be a valid key in `erl_anno` soon.)
  • Loading branch information
gomoripeti committed Apr 11, 2021
1 parent f6311df commit 86f3833
Show file tree
Hide file tree
Showing 3 changed files with 654 additions and 634 deletions.
Loading

0 comments on commit 86f3833

Please sign in to comment.