Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to parse warning - [{:<, 1}, {:_ 1}, {:atom_part, 1, 'c'} ... #363

Open
sascha-wolf opened this issue Sep 24, 2019 · 0 comments
Open

Comments

@sascha-wolf
Copy link

Environment

Elixir: 1.8.1 (OTP 20)
Erlang: 21.3.3

Dialyxir: 1.0.0-rc.7 (also reproducible on master - 50eb422)

Error

[{:<, 1}, {:_, 1}, {:atom_part, 1, 'c'}, {:atom_part, 1, 'o'}, {:atom_part, 1, 'n'}, {:atom_part, 1, 'n'}, {:atom_part, 1, '@'}, {:int, 1, 1}, {:",", 1}, {:"{", 1}, {:atom_full, 1, '\'error\''}, {:",", 1}, {:"<<", 1}, {:int, 1, 70}, {:":", 1}, {:int, 1, 8}, {:atom_part, 1, '/'}, {:atom_part, 1, 'i'}, {:atom_part, 1, 'n'}, {:atom_part, 1, 't'}, {:atom_part, 1, 'e'}, {:atom_part, 1, 'g'}, {:atom_part, 1, 'e'}, {:atom_part, 1, 'r'}, {:atom_part, 1, '-'}, {:atom_part, 1, 'u'}, {:atom_part, 1, 'n'}, {:atom_part, 1, 'i'}, {:atom_part, 1, 't'}, {:":", 1}, {:int, 1, 1}, {:",", 1}, {:int, 1, 97}, {:":", 1}, {:int, 1, 8}, {:atom_part, 1, '/'}, {:atom_part, 1, 'i'}, {:atom_part, 1, 'n'}, {:atom_part, 1, 't'}, {:atom_part, 1, 'e'}, {:atom_part, 1, 'g'}, {:atom_part, 1, 'e'}, {:atom_part, 1, 'r'}, {:atom_part, 1, '-'}, {:atom_part, 1, 'u'}, {:atom_part, 1, 'n'}, {:atom_part, 1, 'i'}, {:atom_part, 1, ...}, {:":", ...}, {...}, ...]

Legacy warning:

lib/my_project/controllers/my_controller.ex:69: The pattern <_conn@1, {'error', <<70:8/integer-unit:1,97:8/integer-unit:1,105:8/integer-unit:1,108:8/integer-unit:1,101:8/integer-unit:1,100:8/integer-unit:1,32:8/integer-unit:1,116:8/integer-unit:1,111:8/integer-unit:1,32:8/integer-unit:1,105:8/integer-unit:1,110:8/integer-unit:1,116:8/integer-unit:1,101:8/integer-unit:1,114:8/integer-unit:1,112:8/integer-unit:1,114:8/integer-unit:1,101:8/integer-unit:1,116:8/integer-unit:1,32:8/integer-unit:1,97:8/integer-unit:1,110:8/integer-unit:1,115:8/integer-unit:1,119:8/integer-unit:1,101:8/integer-unit:1,114:8/integer-unit:1,32:8/integer-unit:1,102:8/integer-unit:1,114:8/integer-unit:1,111:8/integer-unit:1,109:8/integer-unit:1,32:8/integer-unit:1,66:8/integer-unit:1,79:8/integer-unit:1,82:8/integer-unit:1,71:8/integer-unit:1,46:8/integer-unit:1>>}> can never match the type <_,{'error',atom() | [any(),...] | #{'__exception__':=_, '__struct__':='Elixir.Redix.ConnectionError' | 'Elixir.Redix.Error', 'message'=>binary(), 'reason'=>atom()}}>

mix dialyzer --format raw

{:warn_matching, {'lib/my_project/controllers/my_controller.ex', 69}, {:pattern_match, ['pattern <_conn@1, {\'error\', <<70:8/integer-unit:1,97:8/integer-unit:1,105:8/integer-unit:1,108:8/integer-unit:1,101:8/integer-unit:1,100:8/integer-unit:1,32:8/integer-unit:1,116:8/integer-unit:1,111:8/integer-unit:1,32:8/integer-unit:1,105:8/integer-unit:1,110:8/integer-unit:1,116:8/integer-unit:1,101:8/integer-unit:1,114:8/integer-unit:1,112:8/integer-unit:1,114:8/integer-unit:1,101:8/integer-unit:1,116:8/integer-unit:1,32:8/integer-unit:1,97:8/integer-unit:1,110:8/integer-unit:1,115:8/integer-unit:1,119:8/integer-unit:1,101:8/integer-unit:1,114:8/integer-unit:1,32:8/integer-unit:1,102:8/integer-unit:1,114:8/integer-unit:1,111:8/integer-unit:1,109:8/integer-unit:1,32:8/integer-unit:1,66:8/integer-unit:1,79:8/integer-unit:1,82:8/integer-unit:1,71:8/integer-unit:1,46:8/integer-unit:1>>}>', '<_,{\'error\',atom() | [any(),...] | \#{\'__exception__\':=_, \'__struct__\':=\'Elixir.Redix.ConnectionError\' | \'Elixir.Redix.Error\', \'message\'=>binary(), \'reason\'=>atom()}}>']}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant