summaryrefslogtreecommitdiff
path: root/test/files/run
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | Merge pull request #2675 from soc/SI-7599Adriaan Moors2013-06-261-8/+12
|\ \ \ \ \ \ \ \ | |_|_|_|_|_|/ / |/| | | | | | | SI-7599 Modify methods to be non-tail-callable ...
| * | | | | | | SI-7599 [Avian] Prevent TCO in test to inspect stackSimon Ochsenreither2013-06-261-8/+12
| | |/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | This commit modifies methods in the test to be non-tail-callable to prevent Avian from eliding the stack frames we want to inspect.
* | | | | | | Merge pull request #2659 from retronym/ticket/7584Adriaan Moors2013-06-253-0/+21
|\ \ \ \ \ \ \ | |_|/ / / / / |/| | | | | | SI-7584 Fix typer regression with by-name parameter types
| * | | | | | SI-7584 Test and spurious warning fix for by-name closuresJason Zaugg2013-06-163-0/+21
| | |_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | The enclosed test case exercises by-name closures, which were the subject of the previous commit. In the process, a spurious warning was eliminated.
* | | | | | SI-7569 Fix end position in PostfixSelect treeFrançois Garillot2013-06-242-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | introduced in 5b54681: the end position of Postfix operators should take the operator length into account. review by @som-snytt
* | | | | | Merge pull request #2637 from retronym/ticket/7439Paul Phillips2013-06-234-0/+40
|\ \ \ \ \ \ | |_|/ / / / |/| | | | | SI-7439 Avoid NPE in `isMonomorphicType` with stub symbols. …
| * | | | | SI-7439 Avoid NPE in `isMonomorphicType` with stub symbols.Jason Zaugg2013-06-134-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `originalInfo` can return null for stub symbols; deal with that as we used to before a regression in 016bc3db. After this change, we can once again delete A_1.class and still compile code instantiating B_1. (A_1 is only referred to in a method signature of B_1 which is not called from our code.) scala> new B_1 warning: Class A_1 not found - continuing with a stub. res0: B_1 = B_1@5284b8f9 In practice, this situation arises when someone uses a third party class that was compiled against other libraries not avaialable on the current compilation classpath.
* | | | | | SI-7292 Fixes test failures by updating *.check filesSimon Ochsenreither2013-06-212-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Looks like partest's confusion about / vs. \ was fixed between the original Jenkins run of the fix for SI-7292 and its merge.
* | | | | | Merge pull request #2635 from retronym/ticket/7151Grzegorz Kossakowski2013-06-192-0/+30
|\ \ \ \ \ \ | | | | | | | | | | | | | | SI-7151 Emit final in bytecode for final inner classes.
| * | | | | | SI-7151 Emit final in bytecode for final inner classes.Jason Zaugg2013-06-072-0/+30
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As we did before a regression in 18efdedfb / SI-5676. This commit tightens up the condition in which the FINAL modifier is omitted; it now *only* does this for the module classes of nested objects.
* | | | | | Merge pull request #2657 from gkossakowski/junit-masterGrzegorz Kossakowski2013-06-191-174/+0
|\ \ \ \ \ \ | | | | | | | | | | | | | | Merge JUnit support into master
| * | | | | | Move WeakHashSetTest to junit tests.Grzegorz Kossakowski2013-06-161-174/+0
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | The WeakHashSetTest was written as unit test but put into partest's `run` category as we were missing direct unit testing support. That got fixed so moving the test now.
* | | | | | Merge pull request #2602 from t3hnar/Duration.toCoarsestAdriaan Moors2013-06-181-0/+28
|\ \ \ \ \ \ | | | | | | | | | | | | | | Add Duration.toCoarsest method
| * | | | | | Add Duration.toCoarsest methodYaroslav Klymko2013-06-101-0/+28
| | | | | | |
* | | | | | | Merge pull request #2561 from soc/SI-7479Adriaan Moors2013-06-183-2/+58
|\ \ \ \ \ \ \ | |_|/ / / / / |/| | | | | | SI-7479 Make test/files/run/tailcalls.scala pass on Avian
| * | | | | | SI-7479 Make test/files/run/tailcalls.scala pass on AvianSimon Ochsenreither2013-06-102-1/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit modifies the test and check file to use the new diff filter.
| * | | | | | SI-7479 Add avian option to partest's diff filter...Simon Ochsenreither2013-06-061-1/+1
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | ... so that the different results of the test on Avian can be specified in the check file.
* | | | | | Merge branch '2.10.x' into topic/merge-v2.10.2-RC1-35-ga54d86b-to-masterJason Zaugg2013-06-1010-11/+3128
|\ \ \ \ \ \ | | |_|_|/ / | |/| | | | | | | | | | | | | | | | Conflicts: src/partest/scala/tools/partest/DirectTest.scala
| * | | | | Merge pull request #2606 from JamesIry/2.10.x_classfile_52Jason Zaugg2013-06-094-11/+87
| |\ \ \ \ \ | | | | | | | | | | | | | | Test for reading JDK 8 (classfile format 52) class files.
| | * | | | | Refactor testing logic for only running under certain JDK versionsJames Iry2013-06-043-18/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We had several tests designed to only run if the JDK version was at least some specified version. This commit refactors that common logic into DirectTest.
| | * | | | | Test for reading JDK 8 (classfile format 52) class files.James Iry2013-05-292-0/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit includes a test for reading JDK 8 (classfile format 52) class files, in particular default (aka defender) methods. It uses ASM to generate an interface with default methods then exercises that interface from Scala. Surprisingly no changes are necessary to the Scala code base to support reading format 52 class files. Because the test can only run under JDK 8, the JDK version is checked and the expected output is synthesized for previous versions.
| * | | | | | Merge pull request #2611 from retronym/ticket/6481Paul Phillips2013-06-082-0/+17
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | SI-6841 Fix bug at the intersection of DelayedInit and named args
| | * | | | | | SI-6841 Fix bug at the intersection of DelayedInit and named argsJason Zaugg2013-05-302-0/+17
| | |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The DelayedInit transformation analyses the constructor to partition regular initialization from calls to super constructors / trait initializers. It failed to find such super calls if they were nested in a Block, which can happens when using named or default arguments. This commit makes that code peer into Blocks to correctly partition the constructor statements. This change doesn't affect the result of run/t4680.scala, which was mentioned in nearby comments and which chronicles bugs with DelayedInit when used in inheritance hierarchies.
| * | | | | | Merge pull request #2629 from retronym/ticket/7558Paul Phillips2013-06-081-0/+9
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | SI-7558 Fix capture of free local vars in toolbox compiler
| | * | | | | | SI-7558 Fix capture of free local vars in toolbox compilerJason Zaugg2013-06-051-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was creating an `ObjectRef[<notype>]` because of a small bug in `capturedVariableType`.
| * | | | | | | Merge pull request #2626 from retronym/ticket/7556Adriaan Moors2013-06-053-0/+3015
| |\ \ \ \ \ \ \ | | |/ / / / / / | |/| | | | | | SI-7556 Fix runtime reflection involving ScalaLongSignature
| | * | | | | | SI-7556 Fix runtime reflection involving ScalaLongSignatureJason Zaugg2013-06-053-0/+3015
| | |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Scala type information is stored in classfiles in encoded in a String in the ScalaSignature annotation. When it is too big for a single String, it is split into an array of Strings in a different annotation, ScalaLongSignature. The enclosed test, with a class containing 3000 methods, uses the latter. It exposes a bug in the way runtime reflection decodes that data. It must concatentate and *then* decode, rather that the other way around.
* | | | | | | Merge pull request #2610 from axel22/issue/7498Jason Zaugg2013-06-091-0/+20
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | SI-7498 ParTrieMap.foreach no longer crashes
| * | | | | | | SI-7498 ParTrieMap.foreach no longer crashesAleksandar Prokopec2013-05-301-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, the `split` method of the `ParTrieMap` iterator threw an exception when splitting a splitter that iterated over nodes whose hash codes collide. This was due to reusing the iterator of the list of colliding keys rather than creating a new splitter. This commit changes the `subdivide` method to create a new iterator using the factory method of the current trie map iterator rather than returning a `LinearSeqLike` iterator.
* | | | | | | | Merge pull request #2630 from retronym/ticket/6308Jason Zaugg2013-06-092-0/+57
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | SI-6308 Specialize methods that have some unspecialized params
| * | | | | | | | SI-6308 Specialize methods that have some unspecialized paramsJason Zaugg2013-06-052-0/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a continuation of 1591c14e50, which didn't go far enough to handle method calls with a mix of specialized and unspecialized type parameters. This commit modifies `specSym` to calculate the residual type of the original method after specialized type parameters have been removed and the type environment of the candidate specialized variant has been subsituted. For example, here is trace of `specSym` when searcing for the specialized variant of `f4` in the enclosed test: tree = Main.this.f4[Nothing, Int] tree.tpe = (a: Int, b: List[(Int, Nothing)])String fun.tpe = [B, A](a: A, b: List[(A, B)])String residualTreeType = [B](a: Int, b: List[(Int, B)])String memberType = [B](a: Int, b: List[(Int, B)])String env = Map(type A -> Int) doesConform = true A few "todo" tests are included that highlight an endemic issue with the current specialization implementation: type parameters that show up after `uncurry` might be clones of the original symbols from typer, if they have been through a TypeMap (e.g. within a call to `uncurryTreeType`). So testing them for existence with the `typeEnv` map is fruitless. No amount of `atPhase` acrobatics can rescue us from this; we need to transport this information in a symbol-cloning resiliant manner. Maybe Symbol Attachments?
* | | | | | | | | Merge pull request #2642 from soc/SI-7564Jason Zaugg2013-06-091-1/+1
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | SI-7564 Fix detection of reflective calls on Avian
| * | | | | | | | | SI-7564 Fix detection of reflective calls on AvianSimon Ochsenreither2013-06-081-1/+1
| | |_|_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Base_1.scala checks whether reflection was used by inspecting the stacktrace and looking for “java.lang.reflect.”. The stacktrace looks differently on Avian and therefore the test fails. This change looks for “sun.reflect.” instead, which seems to work on OpenJDK and Avian.
* | | | | | | | | Merge pull request #2639 from retronym/ticket/2464Paul Phillips2013-06-083-0/+60
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | SI-2464 Resiliance against missing InnerClass attributes
| * | | | | | | | | SI-2464 Resiliance against missing InnerClass attributesJason Zaugg2013-06-063-0/+60
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A classfile in the wild related to Vaadin lacked the InnerClasses attribute. As such, our class file parser treated a nested enum class as top-level, which led to a crash when trying to find its linked module. More details of the investigation are available in the JIRA comments. The test introduces a new facility to rewrite classfiles. This commit turns this situation into a logged warning, rather than crashing. Code by @paulp, test by yours truly.
* | | | | | | | | Merge pull request #2622 from scalamacros/pullrequest/paradisePaul Phillips2013-06-073-0/+24
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / |/| | | | | | | | Backport from paradise/macros
| * | | | | | | | cleans up 82f0925Eugene Burmako2013-06-033-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Updates comments, implements accidentally forgotten IMPLPARAM_TREE, creates a test to ensure that nothing else is overseen.
* | | | | | | | | Merge pull request #2605 from JamesIry/weak_hashset_uniquesGrzegorz Kossakowski2013-06-041-0/+174
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | SI-7149 Use a WeakHashSet for type uniqueness
| * | | | | | | | | SI-7150 Replace scala.reflect.internal.WeakHashSetJames Iry2013-06-041-0/+174
| | |_|/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replaces scala.reflect.internal.WeakHashSet with a version that * extends the mutable.Set trait * doesn't leak WeakReferences * is unit tested
* | | | | | | | | Merge branch 'pr/merge-2.10.2' into masterPaul Phillips2013-06-046-0/+76
|\ \ \ \ \ \ \ \ \ | | |_|_|/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * pr/merge-2.10.2: SI-7375 ClassTag for value class aliases SI-7507 Fix lookup of private[this] member in presence of self type. SI-7532 Fix regression in Java inner classfile reader SI-7517 Fix higher kinded type inference regression SI-7516 Revert "SI-7234 Make named args play nice w. depmet types" A test case for a recent LUB progression. SI-7421 remove unneeded extra-attachement in maven deploy SI-7486 Regressions in implicit search. SI-7509 Avoid crasher as erronous args flow through NamesDefaults SI-6138 Centralize and refine detection of `getClass` calls SI-7497 Fix scala.util.Properties.isMac SI-7473 Bad for expr crashes postfix Increase build.number to 2.10.3 SI-7391 Always use ForkJoin in Scala actors on ... ... Java 6 and above (except when the porperty actors.enableForkJoin says otherwise) Reimplementing much of the DefaultPromise methods Optimizations: 1) Avoiding to call 'synchronized' in tryComplete and in tryAwait 2) Implementing blocking by using an optimized latch so no blocking ops for non-blockers 3) Reducing method size of isCompleted to be cheaper to inline 4) 'result' to use Try.get instead of patmat c.typeCheck(silent = true) now suppresses ambiguous errors Conflicts: bincompat-backward.whitelist.conf bincompat-forward.whitelist.conf src/compiler/scala/reflect/macros/contexts/Typers.scala src/compiler/scala/reflect/reify/package.scala src/compiler/scala/tools/nsc/symtab/classfile/ClassfileParser.scala src/compiler/scala/tools/nsc/typechecker/NamesDefaults.scala src/compiler/scala/tools/nsc/typechecker/Typers.scala src/compiler/scala/tools/reflect/ToolBoxFactory.scala src/library/scala/concurrent/impl/Promise.scala src/reflect/scala/reflect/internal/Types.scala
| * | | | | | | | Merge pull request #2609 from retronym/ticket/7507Paul Phillips2013-06-031-0/+31
| |\ \ \ \ \ \ \ \ | | |_|_|_|_|_|_|/ | |/| | | | | | | SI-7507 Fix lookup of private[this] member in presence of self type.
| | * | | | | | | SI-7507 Fix lookup of private[this] member in presence of self type.Jason Zaugg2013-05-311-0/+31
| | | |_|_|/ / / | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the following code: trait Cake extends Slice trait Slice { self: Cake => // must have self type that extends `Slice` private[this] val bippy = () // must be private[this] locally(bippy) } `ThisType(<Slice>)`.findMember(bippy)` excluded the private local member on the grounds that the first class in the base type sequence, `Cake`, was not contained in `Slice`. scala> val thisType = typeOf[Slice].typeSymbol.thisType thisType: $r.intp.global.Type = Slice.this.type scala> thisType.baseClasses res6: List[$r.intp.global.Symbol] = List(trait Cake, trait Slice, class Object, class Any) This commit changes `findMember` to use the symbol of the `ThisType`, rather than the first base class, as the location of the selection.
| * / | | | | | SI-7375 ClassTag for value class aliasesEugene Burmako2013-05-315-0/+45
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | reifyRuntimeClass now always dealiases its argument prior to processing.
* | | | | | | Revert "SI-7517 type constructors too eagerly normalized."Paul Phillips2013-06-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 14534c693d2eb6acafaf8244c14b5643388fbd67. It turns out this approach was breaking the working variations in the submitted test case even as it was unbreaking the unworking one, but I never managed to uncomment them. Fortunately retronym's test case was not so lackadaisical.
* | | | | | | Merge pull request #2615 from paulp/issue/7517Paul Phillips2013-06-031-1/+1
|\ \ \ \ \ \ \ | |_|_|/ / / / |/| | | | | | SI-7517 type constructors too eagerly normalized.
| * | | | | | SI-7517 type constructors too eagerly normalized.Paul Phillips2013-05-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I think 403eadd0f1 was largely a symptomatic remedy (not that we shouldn't harden against such outcomes) and that this commit gets closer to the root causes. The unanticipated change to test/files/run/t6113.check is like a cry of support from the jury box. -Foo[[X](Int, X)] +Foo[AnyRef{type l[X] = (Int, X)}#l] We should continue to look at calls to normalize with grave suspicion.
* | | | | | | Merge pull request #2577 from scalamacros/pullrequest/paradiseEugene Burmako2013-06-03153-250/+328
|\ \ \ \ \ \ \ | |_|_|_|_|_|/ |/| | | | | | Backport from paradise/macros
| * | | | | | refactors macro compilationEugene Burmako2013-05-287-2/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Upgrades the way that macro defs are compiled by factoring out most of the logic in typedMacroBody and related errors in ContextErrors into an standalone cake. This leads to tighter cohesion and better code reuse as the cake is isolated from the rest of the compiler and is much easier to evolve than just a method body. Increased convenience of coding macro compilation allowed me to further clarify the implementation of the macro engine (e.g. take a look at Validators.scala) and to easily implement additional features, namely: 1) Parameters and return type of macro implementations can now be plain c.Tree's instead of previously mandatory c.Expr's. This makes macros more lightweight as there are a lot of situations when one doesn't need to splice macro params (the only motivation to use exprs over trees). Also as we're on the verge of having quasiquotes in trunk, there soon will be no reason to use exprs at all, since quasiquotes can splice everything. 2) Macro implementations can now be defined in bundles, standalone cakes built around a macro context: http://docs.scala-lang.org/overviews/macros/bundles.html. This further reduces boilerplate by simplifying implementations complex macros due to the fact that macro programmers no longer need to play path-dependent games to use helpers.
| * | | | | | refactors macro testsEugene Burmako2013-05-28142-248/+281
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | putting in a nutshell, this patch: * condenses some macro-XXX-a/b/c/... bundles * renames some tests to prepare for other macro flavors * introduces some additional tests
| * | | | | | macro engine refactoringEugene Burmako2013-05-286-3/+24
| | |_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Macro impl bindings now store more information in signatures. Previously it was a flattened List[Int] corresponding to flattened paramss, now it's List[List[Int]] to preserve the lengths of parameter lists. Also now we distinguish between c.Expr parameters and others. Previously actual and reference macro signatures were represented as tuples of vparamss, rets, and sometimes tparams. Now they are all abstracted behind MacroImplSig. Finally this patch provides better error messages in cases of argsc <-> paramsc and argc <-> paramc mismatches.