summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #2138 from retronym/ticket/6576-null-strikes-backJames Iry2013-02-191-2/+6
|\ | | | | SI-6576 Workaround / diagnostic for IDE NPE.
| * SI-6576 Workaround / diagnostic for IDE NPE.Jason Zaugg2013-02-191-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Seems like this was too optimistic: > // later by lukas: disabled when fixing SI-5975 > // i think it cannot happen anymore - restored the null check - added logging when we set the namer in this attachment, in the hope of spotting a pattern in the wild. We don't have a test case yet; if we did we could most likely have a more principled fix. But this should suffice for 2.10.1.
* | Merge pull request #2140 from ↵James Iry2013-02-193-4/+32
|\ \ | | | | | | | | | | | | viktorklang/wip-init-bug-executioncontextimpl-2.10.1 Fixing initialization order bug in ExecutionContextImpl, regression from...
| * | SI-7146 - Fixing checkinit bug in ExecutionContextImpl and adding testViktor Klang2013-02-193-4/+32
|/ /
* | Merge pull request #2128 from retronym/ticket/7128James Iry2013-02-192-1/+4
|\ \ | |/ |/| SI-7128 Fix regression in copyToArray for empty arrays
| * SI-7128 Fix regression in copyToArray for empty arraysJason Zaugg2013-02-142-1/+4
|/
* Merge pull request #2122 from adriaanm/revert-pr-1403James Iry2013-02-127-236/+31
|\ | | | | Revert #1403: binary incompatibilities in scala-swing
| * check scala-swing for binary compatibilityAdriaan Moors2013-02-121-0/+31
| |
| * [nomaster] Revert "Added a Swing ColorChooser wrapper"Adriaan Moors2013-02-123-120/+0
| | | | | | | | | | | | This reverts commit 08ab007c5c97f153902c4ac58f87e30fbf7cf99f. This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] Revert "Added a Swing PopupMenu wrapper"Adriaan Moors2013-02-123-116/+0
|/ | | | | | This reverts commit bdff881f8a15d4de0c0ff2aa2427f0d8244d2d42. This is necessary to maintain binary compatibility with 2.10.0.
* Merge pull request #2103 from adriaanm/bin-compatv2.10.1-RC1Adriaan Moors2013-02-1120-236/+792
|\ | | | | Forward and backward binary compatibility between 2.10.0 and 2.10.1-RC1
| * [nomaster] Revert "SI-6548 reflection now correctly enters jinners"Adriaan Moors2013-02-107-64/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 54a84a36d5b435a787d93ca48d45399136c7e162. This is necessary to maintain binary compatibility with 2.10.0. run/t6989.check had to be updated as it also (indirectly) tested SI-6548 Conflicts: test/files/lib/javac-artifacts.jar.desired.sha1 test/files/run/t6548.check test/files/run/t6548/Test_2.scala
| * [nomaster] inline importPrivateWithinFromJavaFlags into SymbolTableAdriaan Moors2013-02-093-28/+19
| | | | | | | | | | | | This reworks 02ed5fb so that we don't change JavaUniverse's super classes. This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] Revert "cosmetic renamings in runtime reflection"Adriaan Moors2013-02-094-54/+54
| | | | | | | | | | | | This reverts commit 0429f0fd9224499cd8b606490d04b1a8dcffbca8. This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] refactor AdaptedForkJoinTask, uncaughtExceptionHandlerAdriaan Moors2013-02-092-28/+25
| | | | | | | | | | | | Inlined AdaptedForkJoinTask, made uncaughtExceptionHandler private[this]. This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] can't add new class BatchingExecutorAdriaan Moors2013-02-093-130/+113
| | | | | | | | This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] bring back SerializeStart from fa3b8040ebAdriaan Moors2013-02-092-10/+14
| | | | | | | | This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] duplicate tailImpl as a private methodAdriaan Moors2013-02-093-5/+13
| | | | | | | | | | | | | | | | Reworks d526f8bd74. This is necessary to maintain binary compatibility with 2.10.0. matchName="scala.collection.mutable.MutableList.tailImpl" problemName=MissingMethodProblem
| * [nomaster] Revert "SI-4664 Make scala.util.Random Serializable"Adriaan Moors2013-02-093-25/+10
| | | | | | | | | | | | | | | | | | Also revert "SI-4664 [Make scala.util.Random Serializable] Add test case" This reverts commit 0b92073a38f9d1823f051ac18173078bfcfafc8a. This reverts commit 2aa66bec86fd464712b0d15251cc400ff9d52821. This is necessary to maintain binary compatibility with 2.10.0.
| * [nomaster] Revert "Fixes SI-6521, overrides Range#head to be faster"Adriaan Moors2013-02-092-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit a557a973608a75c7a02f251bbcf49fe6f6b6655e. This is necessary to maintain binary compatibility with 2.10.0. Mima says: matchName="scala.collection.immutable.Range.head" problemName=IncompatibleResultTypeProblem The bridge method appeared because result is now Int, whereas the super-method's result type erases to Object
| * [nomaster] run mima both ways, filter out failuresAdriaan Moors2013-02-093-3/+557
|/ | | | | | | | | | Using @gkossakowski's contribution to mima (in 0.1.5-SNAPSHOT), make sure bc.run doesn't fail by filtering out all binary incompatibilities. Each subsequent commit will comment out the filters it makes irrelevant, until we only need to filter out permitted binary incompatibilities. We only allow binary incompatibilities in scala.reflect.internal.
* Merge pull request #2100 from paulp/pr/fix-super-varargs-savedJames Iry2013-02-096-4/+121
|\ | | | | Fixing binary compat for $super regression
| * Fix for paramaccessor alias regression.Paul Phillips2013-02-084-1/+31
| | | | | | | | | | A binary incompatibility with 2.10.0 revealed a bug I had introduced in c58647f5f2.
| * Expanded bytecode testing code.Paul Phillips2013-02-082-3/+90
| | | | | | | | | | def sameMethodAndFieldSignatures compares two classes to verify they have all the same methods and fields, and no others.
* | Merge pull request #2094 from scalamacros/ticket/6591James Iry2013-02-0844-105/+309
|\ \ | |/ |/| SI-6591 Reify and path-dependent types
| * accommodates pull request feedbackEugene Burmako2013-02-085-17/+68
| | | | | | | | https://github.com/scala/scala/pull/2072
| * term and type reftrees are now reified uniformlyEugene Burmako2013-02-0824-82/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Top-level (i.e. owned by a package) => Ident(symbol) Nested (i.e. owned by an object or a package object) => Select(owner, symbol) Inner (i.e. owned by a static class) => selectTerm/selectType(owner, name) Non-locatable (i.e. everything else) => see GenTrees.scala for more details Changes w.r.t the previous approaches: * Top-level refs are no longer reified as Select(This(package), symbol). Proposed reification scheme is as resistant to resetAttrs as previous one, but is at the same time much shorter. * Refs to definitions from package objects are no longer Ident(symbol). Otherwise reflective compilation of things like `_ :: _` fails. * Contents of Predef._ and scala._ are no longer treated specially. This increases the size of reificode, but is more hygienic.
| * SI-6591 Reify and path-dependent typesDmitry Bushev2013-02-0821-20/+165
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reification scheme changed. Now Select an SelectFromTypeTree trees reified appropriately, as Select and SelectFromTypeTree accordingly. Packages and Predef object was excluded in order not to break the existing reification scheme and not to break tests which rely on it. Reified free terms can contain flag <stable> to make reified values become stable identifiers. For example in the case of reify_newimpl_15.scala class C { type T reify { val v: List[T] = List(2) } } class C reified as free term C$value, and List[C.T] becomes List[C$value().T], so C$value.apply() need to pass stability test isExprSafeToInline at scala.reflect.internal.TreeInfo. For this purpose special case for reified free terms was added to isExprSafeToInline function. test run/reify_newipl_30 disabled due to SI-7082 test t6591_4 moved to pending due to SI-7083
* | Merge pull request #2095 from hubertp/ticket/5675James Iry2013-02-0814-17/+27
|\ \ | | | | | | SI-5675 Discard duplicate feature warnings at a position
| * | SI-5675 Discard duplicate feature warnings at a positionJason Zaugg2013-02-0814-17/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When -feature has not been enabled, we were double counting identical feature warnings that were emitted at the same position. Normal error reporting only reports the first time a warning appears at a position; feature warning counter incrementing should behave the same way. @hubertp: Fixed .check files that were broken in the original commit.
* | | Merge pull request #2092 from lrytz/t7096James Iry2013-02-083-13/+67
|\ \ \ | | | | | | | | SI-7096 SubstSymMap copies trees before modifying their symbols
| * | | SI-7096 SubstSymMap copies trees before modifying their symbolsLukas Rytz2013-02-083-13/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I removed some strange code in a06d31f6a2 and replaced it by something incorrect: SubstSymMap should never have side-effects: otherwise, calling 'tpe1 <: tpe2' for instance would modify the symbols in annotations of tpe2. SubstSymMap now always creates new trees before changing them.
* | | | Merge pull request #2017 from retronym/ticket/6666James Iry2013-02-0820-73/+265
|\ \ \ \ | | | | | | | | | | Booking more progress on SI-6666
| * | | | Class symbols can't be contravariant.Jason Zaugg2013-02-044-1/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | During development of the fix for SI-6666, I encountered: % test/files/pos/t4842.scala test/files/pos/t4842.scala:10: error: contravariant class Bar occurs in covariant position in type ()this.Bar of constructor Bar this(new { class Bar { println(Bar.this); new { println(Bar.this) } }; new Bar } ) // okay I had incorrectly set the INCONSTRUCTOR flag on the class symbol `Bar`. (It isn't directly in the self constructor call, as it is nested an intervening anonymous class.) But, this flag shares a slot with CONTRAVARIANT, and the variance validation intepreted it as such. ClassSymbol already has this code to resolve the ambiguous flags for display purposes: override def resolveOverloadedFlag(flag: Long) = flag match { case INCONSTRUCTOR => "<inconstructor>" // INCONSTRUCTOR / CONTRAVARIANT / LABEL case EXISTENTIAL => "<existential>" // EXISTENTIAL / MIXEDIN case IMPLCLASS => "<implclass>" // IMPLCLASS / PRESUPER case _ => super.resolveOverloadedFlag(flag) } This commit overrides `isContravariant` to reflect the same logic.
| * | | | SI-6666 Catch VerifyErrors in the making in early defs.Jason Zaugg2013-02-023-9/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As we did for self/super calls, add a backstop into explicitouter and lambdalift to check when we try to get an outer pointer to an under-construction instance.
| * | | | Broader checks for poisonous this references.Jason Zaugg2013-02-0212-82/+146
| | | | | | | | | | | | | | | | | | | | Replaces more VerifyErrors with implementation restrictions.
| * | | | Add a test case from the comments of SI-6666.Jason Zaugg2013-02-022-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | This one lands in the new implementation restriction which beats the VerifyError.
| * | | | SI-6666 Account for nesting in setting INCONSTRUCTORJason Zaugg2013-02-025-4/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This flag is calcualed in Namers, and assigned to class and module class symbols that are defined in self/super-calls, and in early definitions. For example, class D is INCONSTRUCTOR in each case below: class C extends Super({class D; ()}) class C(a: Any) { def this(a: Any) = this({class D; ()}) } new { val x = { class D; () } with Super(()) But, the calculation of this flag failed to account for nesting, so it was not set in cases like: class C(a: Any) { def this(a: Any) = this({val x = {class D; ()}; x}) } This patch searches the enclosing context chain, rather than just the immediate context. The search is terminated at the first non term-owned context. In the following example, this avoids marking `E` as INCONSTRUCTOR; only `D` should be. class C extends Super({class D { class E }; ()}) This closes SI-6259 and SI-6506, and fixes one problem in the recently reopened SI-6957.
| * | | | Move a test from pos to run to highlight bytecode deficiencies.Jason Zaugg2013-01-281-5/+14
| | | | | | | | | | | | | | | | | | | | We'll address them in subsequent commits.
* | | | | Merge pull request #2091 from JamesIry/2.10.x_SI-6478James Iry2013-02-083-3/+56
|\ \ \ \ \ | |_|_|_|/ |/| | | | [backport] SI-6478 Fixing JavaTokenParser ident
| * | | | [backport] SI-6478 Fixing JavaTokenParser identJames Roper2013-02-073-3/+56
| | |/ / | |/| | | | | | | | | | | | | | Backport of 256934160007079f473131469af2df4d023c2cfc from PR https://github.com/scala/scala/pull/1466
* | | | Merge pull request #2035 from scalamacros/ticket/6989Eugene Burmako2013-02-087-17/+332
|\ \ \ \ | | | | | | | | | | SI-6989 privateWithin is now populated in reflect
| * | | | introduces an exhaustive java-to-scala testEugene Burmako2013-02-053-17/+262
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Originally composed to accommodate pull request feedback, this test has uncovered a handful of bugs in FromJavaClassCompleter, namely: * SI-7071 non-public ctors get lost * SI-7072 inner classes are read incorrectly I'm leaving the incorrect results of FromJavaClassCompleters in the check file, so that we get notified when something changes there.
| * | | | SI-6989 privateWithin is now populated in reflectEugene Burmako2013-02-047-17/+87
| | | | | | | | | | | | | | | | | | | | | | | | | Runtime reflection in JavaMirrors previously forgot to fill in privateWithin when importing Java reflection artifacts. Now this is fixed.
* | | | | Merge pull request #2085 from scalamacros/ticket/5824Eugene Burmako2013-02-085-5/+25
|\ \ \ \ \ | | | | | | | | | | | | SI-5824 Fix crashes in reify with _*
| * | | | | SI-5824 Fix crashes in reify with _*Evgeny Kotelnikov2013-02-075-5/+25
| | | | | | | | | | | | | | | | | | | | | | | | Reification crashes if "foo: _*" construct is used. This happens besause type tree is represented either with TypeTree, or with Ident (present case), and `toPreTyperTypedOrAnnotated' only matches of the former. The fix is to cover the latter too. A test is included.
* | | | | | Merge pull request #2093 from adriaanm/ticket-6961James Iry2013-02-073-106/+9
|\ \ \ \ \ \ | | | | | | | | | | | | | | SI-6961 no structural sharing in list serialization
| * | | | | | SI-6961 no structural sharing in list serializationAleksandar Prokopec2013-02-073-106/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Revert list serialization back to what it was in 2.9.x and before. Partial revert of a6fcd70b60 e234978dfd, which fixed SI-5374. The ListBuffer part of the fix remains in place.
* | | | | | | Merge pull request #2090 from adriaanm/rebase-pr-2011James Iry2013-02-0710-50/+192
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | SI-6187 Make partial functions re-typable
| * | | | | | | SI-6187 Make partial functions re-typableJason Zaugg2013-02-0710-50/+192
| | |_|_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - `New(tpe)` doesn't survive a `resetAttrs` / typecheck; use a name instead. - Abandon the tree attachment that passed the default case from `typer` to `patmat`; this tree eluded the attribute reset performed in the macro. Instead, add it to the match. Apart from making the tree re-typable, it also exposes the true code structure to macros, which is important if they need to perform other code transformations. - Install original trees on the declared types of the parameters of the `applyOrElse` method to ensure that references to them within the method pick up the correct type parameter skolems upon retypechecking. - Propagate `TypeTree#original` through `copyAttrs`, which is called during tree duplication / `TreeCopiers`. Without this, the original trees that we installed were not visible anymore during `ResetAttrs`. We are not able to reify partial functions yet -- the particular sticking point is reification of the parentage which is only available in the `ClassInfoType`.