aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #2138 from dotty-staging/add-warning-on-missin-scala-scalaDmitry Petrashko2017-03-281-0/+13
|\ | | | | Add a warning and instructions for new users.
| * Add a warning and instructions for new users.Nicolas Stucki2017-03-231-0/+13
| |
* | Merge pull request #2101 from dotty-staging/upgrade/sbt0.13.14Guillaume Martres2017-03-248-54/+201
|\ \ | |/ |/| Upgrade to sbt 0.13.14-RC2, switch to build.sbt
| * Switch to build.sbtGuillaume Martres2017-03-242-23/+41
| | | | | | | | | | Using the same technique than scala-js where we just forward to Build.scala: https://github.com/scala-js/scala-js/pull/2312
| * sbt-bridge: Synchronize unit tests with sbt 0.13.14Guillaume Martres2017-03-244-20/+148
| | | | | | | | | | Also fix a bug where the compiler output for the tests ended up in the wrong directory, causing some new tests from 0.13.14 to fail.
| * Upgrade sbt plugins, remove unused scalastyle pluginGuillaume Martres2017-03-241-5/+3
| |
| * Upgrade to sbt 0.13.14-RC2Guillaume Martres2017-03-242-6/+9
|/ | | | | | Also replace com.typesafe.sbt:sbt-interface by the equivalent org.scala-sbt:interface since the former is not published in 0.13.14 for some reason (https://github.com/sbt/sbt/issues/3012).
* Fix varargs in methods and constructors (#2135)Igor Mielientiev2017-03-2210-1/+57
| | | | | | | * Fix varargs in methods (Issue: #1625) * Fix minor comments * Change varargs parameter message * Fix failed test, fix case for constructor
* Merge pull request #2134 from dotty-staging/fix/incremental-compilation-restartFelix Mulder2017-03-221-4/+64
|\ | | | | Fix incremental compilation not working after restarting sbt
| * Fix incremental compilation not working after restarting sbtGuillaume Martres2017-03-211-4/+64
|/ | | | | | | | | Previously, every time sbt was restarted, `compile` would do a full recompilation. This happened because sbt uses Java serialization to persist the incremental compilation analysis, deserialization was always silently failing because we used to serialize a class from the dotty-compiler jar which is not on the classpath at deserialization time. See the added comments for more details.
* Merge pull request #2133 from dotty-staging/fix/refinedtype-incrementalFelix Mulder2017-03-211-6/+42
|\ | | | | incremental compilation: Fix unstable name hashing for refined members
| * incremental compilation: Fix unstable name hashing for refined membersGuillaume Martres2017-03-211-6/+42
|/
* Merge pull request #2129 from dotty-staging/topic/dottydoc-subprojectDmitry Petrashko2017-03-212-56/+60
|\ | | | | Fix IntellliJ support by making dotty-doc its own subproject
| * Fix IntellliJ support by making dotty-doc its own subprojectFelix Mulder2017-03-212-56/+60
|/
* Merge pull request #2124 from dotty-staging/fix-param-fwdGuillaume Martres2017-03-2010-13/+101
|\ | | | | Fix parameter accessor forwarding
| * Update check fileMartin Odersky2017-03-202-4/+4
| |
| * Only use shadowed when necessaryMartin Odersky2017-03-201-7/+8
| |
| * Add test casesMartin Odersky2017-03-206-3/+80
| |
| * Use shadowing to reference inherited accessors.Martin Odersky2017-03-201-3/+9
| | | | | | | | | | | | Normal references won't work since the referenced accessor has the same name as a private name in the class defining the forwarder. This showed up as pickling failures under separate compilation.
| * Handle shadowed for TermRefWithSigMartin Odersky2017-03-201-4/+8
|/ | | | Making a name shadowed lost the signature before.
* doc-tool/test: Workaround #2112Guillaume Martres2017-03-201-1/+2
|
* Super Bootstrap: Make dottydoc part of the bootstrapGuillaume Martres2017-03-201-11/+10
| | | | | This wasn't done before because dotty could not compile dottydoc, this is now fixed.
* Fix #2084.Dmitry Petrashko2017-03-201-5/+12
|
* Merge pull request #2122 from dotty-staging/fix-i2086Guillaume Martres2017-03-202-0/+9
|\ | | | | Fixed #2086: Add tests for issue that has already been fixed.
| * Fixed #2086: Add tests for issue that has already been fixed.Nicolas Stucki2017-03-202-0/+9
| |
* | Merge pull request #2123 from dotty-staging/fix-i1573Guillaume Martres2017-03-203-0/+15
|\ \ | | | | | | Fixed #1573: Add tests for fixed issue.
| * | Fixed #1573: Add tests for fixed issue.Nicolas Stucki2017-03-203-0/+15
| | |
* | | Merge pull request #2114 from dotty-staging/fix/inline-error-posGuillaume Martres2017-03-201-3/+4
|\ \ \ | |_|/ |/| | Fix position of errors in Inliner TreeTypeMap
| * | Fix position of errors in Inliner TreeTypeMapGuillaume Martres2017-03-161-3/+4
| | |
* | | Merge pull request #2118 from abeln/super-bugDmitry Petrashko2017-03-202-19/+24
|\ \ \ | |_|/ |/| | Fix #2117: bug in typechecking super prefix with invalid enclosing class
| * | Fix bug in typechecking super prefix with invalid enclosing classAbel Nieto2017-03-172-19/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When typechecking class A { C.super.foo() } If C isn't an enclosing class, the compiler was throwing because of an unguarded pattern match. Fix the issue by checking for ErrorType. Tested: Verified that the example above no longer throws. Added a test.
* | | Fix procedure syntax in JavaConvertersValthor Halldorsson2017-03-191-6/+6
| | |
* | | Fix exception caused by attempting to serialize NonEntity valuesValthor Halldorsson2017-03-191-21/+28
| | | | | | | | | | | | - Added explicit checking for NonEntity when serializing DefaultParams
* | | Merge pull request #2111 from dotty-staging/fix/better-lubGuillaume Martres2017-03-184-25/+60
|\ \ \ | | | | | | | | Better type inference in harmonizeUnion
| * | | Better type inference in harmonizeUnionGuillaume Martres2017-03-184-25/+60
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this commit, the added testcase failed because the type of `inv` was inferred to be `Inv[Any]` instead of `Inv[Int]`. The situation looks like this: def inv(cond: Boolean) = if (cond) new Inv(1) // : Inv[A] where A >: Int else Inv.empty // : Inv[A'] where A' unconstrained // : Inv[A] | Inv[A'] To get the type of `inv`, we call `harmonizeUnion` which will take the lub of `Inv[A]` and `Inv[A']`, eventually this mean that we do: A' <:< A But since `harmonizeUnion` uses `fluidly`, this does not result in `A'` getting constrained to be a subtype of `A`, instead we constrain `A` to the upper bound of `A'`: Any <:< A We use `fluidly` to avoid creating OrTypes in `lub`, but it turns out that there is a less aggressive solution: `lub` calls `mergeIfSuper` which then calls `isSubTypeWhenFrozen`, if we just make these subtype calls non-frozen, we can achieve what we want. This is what the new `lub` parameter `canConstrain` allows.
* | | Merge pull request #2110 from dotty-staging/fix/reduce-more-lambdasGuillaume Martres2017-03-184-4/+9
|\ \ \ | | | | | | | | Reduce type lambdas even if variance changes
| * | | Reduce type lambdas even if variance changesGuillaume Martres2017-03-162-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the added testcase failed with (when running with -Ydebug-alias): 2 | def foo = Seq(a) | ^ |covariant type A occurs in invariant position in type => Seq.CC[Cov.this.A] of method foo Because the type parameter of `CC` is invariant. Of course, this is fine because `CC[A]` can be reduced to `Seq[A]`, but before this commit, `TypeApplications#appliedTo` used to disallow reductions that replaced an invariant type parameter with a variant one. I believe that for type inference, only preserving the arity is important, so I removed this restriction.
| * | | New flag -Ydebug-alias to never follow aliases when printing typesGuillaume Martres2017-03-162-1/+2
| | |/ | |/|
* | | Merge pull request #2119 from abeln/period-commentDmitry Petrashko2017-03-181-3/+4
|\ \ \ | | | | | | | | Update periods-related comments
| * | | Update periods-related commentsAbel Nieto2017-03-181-3/+4
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The phase width in a period was bumped from 6 to 7 in https://github.com/lampepfl/dotty/commit/16671a00371df2bdbaf6ae7f51b0ec7191ce94f3 but the comment wasn't updated. Update the comment (and another unrelated comment). Tested: No
* | | Merge pull request #2058 from dotty-staging/fix-2054liu fengyun2017-03-184-4/+23
|\ \ \ | |_|/ |/| | Fix #2054
| * | fix typo in commentliu fengyun2017-03-181-1/+1
| | |
| * | Fix a stupid error in fix of #2054.Dmitry Petrashko2017-03-132-4/+7
| | |
| * | Test that #2054 is fixed.Dmitry Petrashko2017-03-071-0/+13
| | |
| * | Fix #2054: @Static methods may access synthetic private methods stuffDmitry Petrashko2017-03-072-2/+5
| | | | | | | | | | | | | | | | | | Due to way how we desugar lambdas, we can decide to make a lambda static Static methods could refer to those lambdas and we need to make them public
* | | Move 'invalid super qualifier' error to new error format.Abel Nieto2017-03-174-1/+43
| |/ |/| | | | | | | | | | | | | | | As part of https://github.com/lampepfl/dotty/issues/1589, use the new error message for static super references where the qualifier isn't a parent of the class. Tested: Added unit test.
* | Merge pull request #2106 from dotty-staging/fix/param-forwarder-access-take-2odersky2017-03-164-5/+33
|\ \ | | | | | | Alternative fix for #2099: avoid loading a private member when recomputing a NamedType denot
| * | Allow going from non-priv to priv denot when run changesGuillaume Martres2017-03-161-11/+6
| | |
| * | Don't force denotations in asMemberOfGuillaume Martres2017-03-161-5/+6
| | | | | | | | | | | | | | | | | | This was introduced in the previous commit and caused unpickling failures, we are now more conservative and only check the Private flag on SymDenotations so we don't have to load any other denotation.
| * | Fix #2099: avoid loading a private member when recomputing a NamedType denotGuillaume Martres2017-03-164-2/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ParamForwarding creates the following forwarder in B: private[this] def member: Int = super.member Where the type for `super.member` is `TermRef(SubA, member)` and the symbol is the `val member` in `A`. So far this is correct, but in later phases we might call `loadDenot` on this `TermRef` which will end up calling `asMemberOf`, which before this commit just did: prefix.member(name) This is incorrect in our case because `SubA` also happens to have a private `def member`, which means that our forwarder in B now forwards to a private method in a superclass, this subsequently crashes in `ExpandPrivate`. (Note: in the bytecode, a private method cannot have the same name as an overriden method, but this is already worked around in EnsurePrivate.) The fix is simple: when we recompute a member, we should only look at private members if the previous denotation was private.