summaryrefslogtreecommitdiff
path: root/test/files/run/t9097.scala
Commit message (Collapse)AuthorAgeFilesLines
* Disable -Ydelambdafy:method for specialized FunctionNJason Zaugg2015-04-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The Delambdafy phase generates its `FunctionN` subclasses after the specialization phase. As such, `((x: Int) => x).apply(42)` incurs boxing. This commit falls back to the `-Ydelambdafy:inline` in this case. This is done by running the specialization type map over the type of the function, and seeing if anything changes. To make this work robustly, we first need to ensure that the specialization info transformer has processed all the function types. This is not a fundamental limitation; we could in principle generate the specialized code. A followup change will use `-Ydelambdafy:method` as the basis for invokedymnamic lambdas. As part of that stream of work, we will synthesize specialization-aware lambdas, and remove the fallback to `-Ydelambdafy:inline`. I have updated some tests that intend to test the delambdafy transform to avoid use of specialized function types.
* SI-9097 Consolidate testSom Snytt2015-01-201-2/+10
| | | | `pos` test is subsumed by `run`.
* SI-9097 Remove spurious warning about conflicting filenamesLukas Rytz2015-01-201-0/+26
When using delambdafy:method, closure classes are generated late. The class is added to a map and integrated into the PackageDef in transformStats. When declaring a package object, there are potentially multiple PackageDefs for the same package. In this case, the closure class was added to all of them. As a result, GenASM / GenBCode would run multiple times on the closure class. In GenBCode this would trigger a warning about conflicting filenames.