Permalink
Commits on Nov 22, 2011
Commits on Nov 21, 2011
  1. Don't let the user finish the new name refactoring wizard with the or…

    …iginal name.
    
    (cherry picked from commit 89396ef)
    misto committed Nov 21, 2011
  2. Tweaks for Re #1000757

    - configured the new marker ids as extensions, so they are visible in the UI.
    - recursively removed all marker in the projects with invalid classpath, and fixed the test.
    (cherry-picked commit 7ab0683)
    skyluc committed Nov 21, 2011
  3. Better build error management, and cleaned up interactions between bu…

    …ild, compiler settings,
    
    and class path validation errors.
    
    1. The class path validator deletes all Java and Scala error markers *only* when there is an
       class path error.
    2. Build errors, settings errors and class path errors have different marker IDs.
    3. Invalid setting errors are now reported. Until now they went unreported.
    4. Fixed #1000757.(cherry picked from commit 55ae84c)
    (cherry picked from commit e28c174)
    dragos committed Nov 15, 2011
  4. One more try at reducing the amount of output logged by the classfile…

    … provider.
    
    (cherry picked from commit 6f96b20)
    (cherry picked from commit d838fd1)
    dragos committed Nov 17, 2011
  5. Shorter log messages from the ClassFileProvider.(cherry picked from c…

    …ommit bce94f8)
    
    (cherry picked from commit 02a62dd)
    dragos committed Nov 16, 2011
  6. A shot in the dark, since I cannot reproduce this error. However, it …

    …looks reasonable to not crash if the class path is incomplete. This guards against a known SBT bug:
    
    
    harrah/xsbt#117
    
    I also removed some tabs.
    
    Test #1000741.(cherry picked from commit 395bfb0)
    (cherry picked from commit 9fe0846)
    dragos committed Nov 10, 2011
  7. Integrated review comments.

    (cherry picked from commit 76d1db1)
    (cherry picked from commit 7d856bf)
    dragos committed Nov 10, 2011
  8. Don't read classfile bytes if the classfile is not part of a Scala pr…

    …oject. This may cause large delays when the class files are on a network mounted file system.
    
    Fixed #1000742, Fixed #1000233, Fixed #1000643.
    (cherry picked from commit e35df9d)
    (cherry picked from commit 726dd67)
    dragos committed Nov 10, 2011
Commits on Nov 17, 2011
  1. Disabled test because it is making fail the build for 2.8 compiler.

    As a matter of fact, it is really only by chance that with 2.9 the test is passing, and
    a bigger issue is lying behind this test. Look at ticket Re #1000761. The problem is that
    we are not correctly exposing to JDT private values defined in a trait , i.e., the exposed
    getter does not match the name of the method in the binary, which is clearly an issue (for
    instance, I'm pretty convinced that the spurious error _The hierarchy of the type XXX is
    inconsistent_ that can sometimes be shown in the Java editor, is likely to be linked to the
    very same problem).
    
    Since we plan a major re-work of the structure builder for 2.1 I believe it is better to tackle
    this at that point. no review.
    dotta committed Nov 17, 2011
Commits on Nov 16, 2011
  1. Entities nested in a Type Member definition are *not* traversed, beca…

    …use the Eclipse Java Outline that we currently
    
    use does not handle members defined in a {{{ org.eclipse.jdt.internal.core.SourceField }}} (which is the data structure
    we use to expose type members definition to JDT).
    
    For instance, the following is not correctly handled by the Outline when you click on the nested member `a`:
    
        {{{type AkkaConfig = a.type forSome { val a: AnyRef }.
    
    Hence, for safety, currently it is better to skip all children altogether. Fix #1000748.
    dotta committed Nov 14, 2011
  2. Ticket Re #1000741 raised the question of whether we needed an open e…

    …ditor to check if the MethodBinding passed to
    
    the ScalaMethodVerifierProvider is indeed abstract (the reported NPE exception was not generating any issue, it was
    simply creating lot of noise in the Eclipse Error Log view).
    
    The answer is no, and I updated the code accordingly. Now, we check if the MethodBinding belongs to a trait only
    if the MethodBinding is declared in a Scala file (we look at the file's extension to infer this). That makes much
    more sense and allowed to re-enable all tests in jcompiler package.
    
    Any exception occuring in this code is still being logger in the Error Log view, that because I believe that now
    the code should work as expected (and if it doesn't, I'd prefer not to be silent so that the issue is reported and
    we can look into it).
    
    Added also one test to check that the case of a trait providing the implementation of a method declared in a Java
    interface is correctly handled.
    
    Scala entitites with a {{{ protected }}} access modifier are now exposed to JDT as {{{ public }}}. This emulates
    the Scala compiler behavior. Fix #1000751.
    
    Some Scala types (e.g., AnyRef, Any, Array, ...) with no generic signature were not correctly converted in the
    ScalaMethodVerifierProvider. Fix #1000752.
    
    Integrated Iulian's feedback (pull request #42).
    
    Resolved Conflicts:
    
    	org.scala-ide.sdt.core/src/scala/tools/eclipse/jcompiler/ScalaMethodVerifierProvider.scala
    dotta committed Nov 16, 2011
  3. Replaced all calls to ScalaPlugin.check and ScalaPlugin.checkOrElse w…

    …ith Utils.tryExecute.
    
    I believe the latter better describes the method's intention.
    
    (cherry picked from commit 4a1c311)
    dotta committed Nov 16, 2011
Commits on Nov 9, 2011
  1. Cherrypicked fix for #1000406.

    Reverting the revert (that's sounds weird btw): "Revert "Fixes #1000406. Also don't add compiler to the classpath automatically"" and fixed the underlying problem. Also added a bunch of tests for sbt builder for other bugs. Not sure how to force jdk change easily for this bug, so I am leaving the test case open
    
    Cherry-picked from d98125e without ImplicitsHighlighting test.
    
    Added files necessary to initialize workspace for the tests
    (cherry picked from commit a9a3f72)
    
    Finally fixed tests, which revealed problem with the build manager in testSimpleJavaDep test in ScalaJavaDepTest. We seem to still remove java classes and sbt assumes that they are still there.
    (cherry picked from commit 31bb845)
    
    Ignore failing test for now (it is not related to this ticket anyway, but to builder in general. Made smaller jar for compiler testing
    (cherry picked from commit 0c9bb34)
    
    Typo
    (cherry picked from commit 0e60fea)
    
    I was overzealous with my changes. Incorported fix pointed out in the review
    (cherry picked from commit 77472e6)
    hubertp committed Oct 31, 2011
Commits on Nov 8, 2011
  1. The ScalaMethodVerifierProvider needs to access the active project to…

    … query the presentation compiler and retrieve the
    
    symbol associated to a MethodBinding.
    
    To retrieve the active project we need to use the Eclipse Workbench, which is a UI component. Consequently, I had to
    ignore all tests related to the ScalaMethodVerifierProvider, as they would fail in headless mode.
    
    The strategy we used in the past to retrieve the project was simply broken. In fact, it was crashing when the MethodBinding
    was coming from a binary classfile (check Re #1000660 for a practical example).
    
    I'll work on re-enabling them but I'd like to push this forward as it Fixes #1000660, #1000715.
    
    Iulian is right, if the MethodBinding is coming from a binary file, then we don't need to run it through the
    ScalaMethodVerifierProvider, because all the mixed-in methods have been added (therefore Java compilers sees
    the correct types).
    dotta committed Nov 8, 2011
  2. Updated About.

    dotta committed Nov 8, 2011
  3. Decoupled the Scala library version from the Scala compiler version w…

    …hen building the toolchain.
    
    Build the toolchain by using the stable 2.9.1 scala library, and the 2.9.2-SNAPSHOT
    compiler.
    
    Cleaned up build profiles and removed obsolete scripts.(cherry picked from commit 8c8419f)
    Iulian Dragos committed with dragos Nov 6, 2011
Commits on Nov 7, 2011
  1. Merge branch 'issue/classpath-validator-vs-sbt-vs-m2eclipse-1000728' …

    …into release/scala-ide-2.0.x
    skyluc committed Nov 7, 2011
  2. Added test for #1000634

    hubertp committed Nov 7, 2011
  3. Closes #1000634. Minor changes in sbt were already done and published…

    …. Basically the comment information needed to be propagated further to the original eclipse build reporter (that by default handles comments correctly) rather than be ignored inside sbt
    hubertp committed Nov 7, 2011
  4. Fixed #1000480. Added a project chooser.

    If the view is opened without a scala project, a UI allowing to select a project is displayed.
    After selection of a project by the user, the view with the correct interpreter is opened.
    The list of projects is updated as projects are opened, closed, created or deleted.
    skyluc committed Nov 1, 2011
  5. Fixed #1000728. Modified classpath validator to accept multiple scala…

    … library jars of compatible version.
    
    Extended tests for the new cases.
    skyluc committed Nov 7, 2011
  6. Incorporated reviewer comments.

    dragos committed Nov 7, 2011
  7. Copy resources to the output directory. This runs the JDT Java builde…

    …r for this purpose, even when there are no modified Java files.
    
    Fixed #1000636.
    dragos committed Nov 7, 2011
  8. Some merge or pull request accidentally pulled this commit, making th…

    …e 2.0.x branch have the
    
    2.1 version.
    
    Revert "Bumped the version number for master, who becomes the official 2.1.x branch! Champagne!"
    
    This reverts commit 4d4f25e.
    dragos committed Nov 7, 2011
  9. Added test for checking the Outline is correctly built (i.e., types d…

    …eclared inside a module are correctly shown in the Outline). Fixes #1000711.
    dotta committed Nov 7, 2011
Commits on Nov 6, 2011
  1. To be visible from Java sources, classes nested in a module have to b…

    …e exposed as children
    
    of the module's companion class (this matches the Scala compiler's behavior). To this end,
    when traversing a ClassDef tree node, we were checking its symbol's owner to know if the
    declaration was nested in a module. This manipulation was from time to time preventing the
    structure builder to correctly traverse the file (and produced an exception:
    'java.lang.Error: no-symbol does not have owner').
    
    The issue is that symbols in the structure builder have to be handled with care, as we deal
    with trees that are not fully typechecked, and consequently most symbols are not set.
    
    Therefore, I reworked the way we check if a ClassDef is nested in a module, and no symbol is
    used this time to carry out the check.
    
    Furthermore, I noticed a slight regression, i.e., ClassDefs nested in a module where no longer
    shown as children of the module in the Eclipse Outline (this because they were traversed as
    children of the module's companion class, which may not exist in the editor, and hence it would
    not be shown in the Outline).
    The underneath problem is that the Outline is currently too coupled to the structure builder,
    and therefore no real solution exist to correctly build the Outline view (without a major rewriting,
    which it can't happen now).
    The current solution is to show ClassDefs nested in a module twice if both the module and the
    companion class exist. This is not ideal, but in this way ClassDefs nested in a module will
    be reported in the Outline view.
    dotta committed Nov 6, 2011
Commits on Nov 4, 2011
  1. Merge branch 'issue/spurious-errors-clean-build-1000699'

    Iulian Dragos committed Nov 4, 2011
  2. Integrated reviews.

    dragos committed with Iulian Dragos Nov 1, 2011
  3. Reworked the way the presentation compiler is restarted when projects…

    … change.
    
    - A project resets the presentation compiler of all projects that depend on it after a successful build.
    - A project resets its own presentation compiler when one of the projects it depends on has changes (such as a class path change)
    - A class path change, or an added source file, restarts the PC
    
    Fixed #1000699. Test #1000645.
    dragos committed with Iulian Dragos Oct 31, 2011
  4. Fixed wrong assertion in type mapper for scala.Array. The Array objec…

    …t does not take
    
    type parameters.
    dragos committed with Iulian Dragos Oct 30, 2011