Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
erlfmt_ast returns pos as erl_anno:anno() instead of a map
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