Open class implementing trait in editor or search for trait results in error

Open
#548 1 comment 1 reaction 1 assignee View on GitHub

@eric-milles is already working on this.

Since Apr 12, 2018.

Assessment

This issue has not been assessed yet.

Description

bug

Open the class in the Groovy Editor and the error below is logged. This may be related to #175, since the referenced trait is only reconciled to compile phase 3.

MyClass.groovy:

class MyClass implements MyTrait {
}

MyTrait.groovy:

trait MyTrait {
  def m() { 'm' }
}

Groovy:Groovy compiler error: exception in phase 'canonicalization' in source unit '...\eclipse-space\Groovy\src\main\traits2\MyClass.groovy' JDTClassNode.getTypeClass() cannot locate class for traits.MyTrait using transform loader groovy.lang.GroovyClassLoader@36edbb99

Dominant language
Java
Stars
681
Forks
197
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from groovy/groovy-eclipse

All issues in groovy/groovy-eclipse

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.