katana-code
katana-code copied to clipboard
ktn_dodger can't parse -else.
Bug Description
When running ktn_dodger:parse_file/1,2 on a file with an -else., it reports an error (or, if using no_fail, it just parses that as text instead of an actual attribute).
To Reproduce
Try running ktn_parse:parse_file/1,2 on the following file…
-module x.
-export [x/0].
-ifdef(VAR).
x() ->
var.
-else.
x() ->
not_var.
-endif.
Expected Behavior
-else. to be parsed as an attribute.
Additional Context
- OS: MacOS
- Erlang version: OTP25