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

Exception: Don't know how to resolve variable in match #568

Closed
mbriggs opened this issue Dec 20, 2016 · 1 comment
Closed

Exception: Don't know how to resolve variable in match #568

mbriggs opened this issue Dec 20, 2016 · 1 comment
Labels
Milestone

Comments

@mbriggs
Copy link

mbriggs commented Dec 20, 2016

Version

4.7.0

Exception

I renamed a module from Customizer.PrintAsset to Customizer.Wrap. Went to another file that had

alias Customizer.{PrintAsset, Artwork, NPH}

backspaced through the PrintAsset, part and changed it to

alias Customizer.{Wrap, Artwork, NPH}

during that, the exception fired.

side note: this is the first error I have noticed in 4.7 so far!

Message

Don't know how to resolve variable in match

Excerpt

{wIntellijIdeaRulezzz , Artwork, NPH}

Line(s) 2-2

Element Class Name

org.elixir_lang.psi.impl.ElixirMultipleAliasesImpl

Stacktrace

org.elixir_lang.errorreport.Logger.error(Logger.java:51)
org.elixir_lang.errorreport.Logger.error(Logger.java:34)
org.elixir_lang.psi.scope.Variable.execute(Variable.java:141)
org.elixir_lang.psi.impl.ElixirPsiImplUtil.processDeclarationsRecursively(ElixirPsiImplUtil.java:1708)
org.elixir_lang.psi.impl.ElixirPsiImplUtil.processDeclarations(ElixirPsiImplUtil.java:1574)
org.elixir_lang.psi.impl.ElixirMultipleAliasesImpl.processDeclarations(ElixirMultipleAliasesImpl.java:52)
com.intellij.psi.util.PsiTreeUtil.treeWalkUp(PsiTreeUtil.java:1064)
org.elixir_lang.psi.scope.variable.Variants.lookupElementList(Variants.java:27)
org.elixir_lang.reference.Callable.getVariants(Callable.java:583)
com.intellij.codeInsight.completion.CompletionData.completeReference(CompletionData.java:292)
com.intellij.codeInsight.completion.CompletionVariant.addReferenceCompletions(CompletionVariant.java:164)
com.intellij.codeInsight.completion.CompletionData.completeReference(CompletionData.java:97)
com.intellij.codeInsight.completion.LegacyCompletionContributor.lambda$completeReference$0(LegacyCompletionContributor.java:71)
com.intellij.codeInsight.completion.LegacyCompletionContributor.processReference(LegacyCompletionContributor.java:125)
com.intellij.codeInsight.completion.LegacyCompletionContributor.processReferences(LegacyCompletionContributor.java:108)
com.intellij.codeInsight.completion.LegacyCompletionContributor.completeReference(LegacyCompletionContributor.java:69)
com.intellij.codeInsight.completion.LegacyCompletionContributor.fillCompletionVariants(LegacyCompletionContributor.java:52)
com.intellij.codeInsight.completion.CompletionService.getVariantsFromContributors(CompletionService.java:81)
com.intellij.codeInsight.completion.CompletionResultSet.runRemainingContributors(CompletionResultSet.java:132)
com.intellij.codeInsight.completion.CompletionResultSet.runRemainingContributors(CompletionResultSet.java:125)
com.intellij.codeInsight.template.impl.LiveTemplateCompletionContributor$2.addCompletions(LiveTemplateCompletionContributor.java:88)
com.intellij.codeInsight.completion.CompletionProvider.addCompletionVariants(CompletionProvider.java:36)
com.intellij.codeInsight.completion.CompletionContributor.fillCompletionVariants(CompletionContributor.java:151)
com.intellij.codeInsight.completion.CompletionService.getVariantsFromContributors(CompletionService.java:81)
com.intellij.codeInsight.completion.CompletionService.performCompletion(CompletionService.java:110)
com.intellij.codeInsight.completion.CompletionProgressIndicator.calculateItems(CompletionProgressIndicator.java:773)
com.intellij.codeInsight.completion.CompletionProgressIndicator.access$500(CompletionProgressIndicator.java:91)
com.intellij.codeInsight.completion.CompletionProgressIndicator$1CalculateItems.run(CompletionProgressIndicator.java:755)
com.intellij.codeInsight.completion.AsyncCompletion.lambda$null$0(CompletionThreading.java:87)
com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:877)
com.intellij.codeInsight.completion.AsyncCompletion.lambda$null$1(CompletionThreading.java:84)
com.intellij.openapi.progress.impl.CoreProgressManager$3.run(CoreProgressManager.java:179)
com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:568)
com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:519)
com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:54)
com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:164)
com.intellij.codeInsight.completion.AsyncCompletion.lambda$startThread$2(CompletionThreading.java:82)
com.intellij.openapi.application.impl.ApplicationImpl$2.run(ApplicationImpl.java:309)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.run(FutureTask.java:266)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
@mbriggs mbriggs changed the title [auto-generated] Exception: Don't know how to resolve variable in match Dec 20, 2016
@KronicDeth
Copy link
Owner

I'm guessing the problem is the leading w, which makes the grammar see it as a variable. This is a true bug since it's obvious that one can enter a lower case variable in that location when editing even though it's not valid grammar for Elixir.

Explanation of error text

IntellijIdeaRulezzz is the temporary text that OpenAPI inserts for completion so that there is always text to complete. The way completion works, an entire copy of the file is generated with the completion text put in place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants