We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Erlang/OTP 26 [erts-14.2.5.2] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1] [jit]
Elixir 1.17.2 (compiled with Erlang/OTP 26)
any
In cases where relevant information is after the operator the returned AST is suboptimal. An example (with cursor marked as |)
|
case foo do %{some: some} -> do_sth(some) %{other: other} = |foo -> {:error, other} end
AST returned
{:case, [line: 1], [ {:foo, [line: 1], nil}, [ do: [ {:->, [line: 1], [ [{:%{}, [line: 1], [some: {:some, [line: 1], nil}]}], {:__block__, [], [ {:do_sth, [line: 1], [{:some, [line: 1], nil}]}, {:=, [line: 1], [ {:%{}, [line: 1], [other: {:other, [line: 1], nil}]}, {:__cursor__, [line: 1], []} ]} ]} ]} ] ] ]}
as if the code was
case foo do %{some: some} -> do_sth(some) %{other: other} = |foo end
This means the cursor is on the wrong case branch and in wrong context.
I understand that the behaviour is a consequence of tokenizer dropping all code after the cursor and in this case the result is ambiguous.
Some ideas.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Elixir and Erlang/OTP versions
Erlang/OTP 26 [erts-14.2.5.2] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1] [jit]
Elixir 1.17.2 (compiled with Erlang/OTP 26)
Operating system
any
Current behavior
In cases where relevant information is after the operator the returned AST is suboptimal. An example (with cursor marked as
|
)AST returned
as if the code was
This means the cursor is on the wrong case branch and in wrong context.
I understand that the behaviour is a consequence of tokenizer dropping all code after the cursor and in this case the result is ambiguous.
Expected behavior
Some ideas.
The text was updated successfully, but these errors were encountered: