aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | Rearrange pickle testsMartin Odersky2016-04-093-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 1) Move passing test to pickling 2) Add test case for #1212 in pending 3) Disable annotations/internal in pickling tests. They lead to a stable symbol error which is explainable (modifiers are read before symbol is created).
| * | | Avoid creating a SourceFile annotation for SourceFile itselfMartin Odersky2016-04-091-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This leads to an infinite cycle when trying to unpickling, because the modifiers and annotations of a symbol are read before the symbol itself is created. See #1212 for the general case.
| * | | Simplify handling of sourcefiles in Tasty infoMartin Odersky2016-04-095-33/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of separate source file sections, pickle SourceFile as an annotation of all toplevel classes. We represent it like this anyway when reading back Tasty-defined classes.
| * | | Store source files as normal paths, not canonical ones.Martin Odersky2016-04-082-2/+16
| | | | | | | | | | | | | | | | This is the same as what Java does for its ClassFile attribute.
| * | | Explain isTyper field in Phase.Martin Odersky2016-04-081-1/+5
| | | |
| * | | Add source file for SourceFile annotationMartin Odersky2016-04-081-0/+10
| | | |
| * | | Fix unpickling of Java SeqLiteralsMartin Odersky2016-04-072-3/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two problems were fixed: - isJava needs to look at function symbol, not its type (references to Java methods get normal MethodTypes not JavMethodTypes) - we also need to handle the case where the repeated argument is wrspped in a type ascription.
| * | | Update TastyFormat for SeqLiteralMartin Odersky2016-04-071-1/+1
| | | | | | | | | | | | | | | | SeqLiteral have an elemTpt, which was missing in format.
| * | | Fix flags when unpickling setters of parameter accessorsMartin Odersky2016-04-072-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | ParamAccessor is not a pickled flag. This is not a problem for normal parameter accessors which are pickled as PARAM fields. But setters of parameter accessors also need to have the flag set (and Deferred reset).
| * | | Test casesMartin Odersky2016-04-072-0/+16
| | | |
| * | | Take SourceFile annotations into account when computing sourceFileMartin Odersky2016-04-072-13/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If a file was loaded from TASTY, it can not still have a non-null source file, since the source file is unpickled into the annotation of a top-level class. Also, fix typo in previous commit.
| * | | Add unpickled source file path as annotation to root symbolsMartin Odersky2016-04-071-4/+8
| | | |
| * | | Pickle sourcefile attribute with canonical pathMartin Odersky2016-04-071-1/+1
| | | |
| * | | Fix reading of SourceFile attribute from TastyMartin Odersky2016-04-071-2/+4
| | | | | | | | | | | | | | | | The previous path name always had a "Simple(...)" wrapped around it.
| * | | Add dotty.annotation.internal.SourceFile annotationMartin Odersky2016-04-072-0/+5
| | | |
| * | | Make first phase of FromTasty not be a TyperMartin Odersky2016-04-071-0/+3
| | | | | | | | | | | | | | | | | | | | `isTyper` is used to enable some error checking and handling, which need not be done when in FromTasty.
| * | | Augment test caseMartin Odersky2016-04-071-0/+14
| | | |
| * | | Treat type parameters of secondary constructors as aliasesMartin Odersky2016-04-072-11/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... of class parameters using the gadt mechanism. Previously they were encoded as aliases by hardcoding alias bounds in the type parameter declaration, but that then leads to weird behavior and failures in unpickling. To make this work, we also need to propagate gadt bounds into the this-call context. Test case in pickling/i1202a.scala.
| * | | Take type parameters for this(...) constructor calls from prefixMartin Odersky2016-04-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, those were inferred from arguments, but this is wrong because we implicitly assume that the type parameters of the constructor and the type parameters of the class are the same. I could not find a test that fails for this. But if you look at the -Xprint:front output of pos/i941.scala, you notice that the inferred argument to the this(...) call was `Nothing` where it should have been `A`.
| * | | Search implicit arguments in the same context as typing explicit onesMartin Odersky2016-04-072-7/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For explicit arguments of this(...) constrictor calls we have a special context that hides members of the current class. But for implicit arguments we did not. This led to implicit shadowing errors for scala.collection.immutable.PagedSeq when secondary constructor type parameters were fixed (as done in subsequent commits).
* | | | Merge pull request #1217 from dotty-staging/fix-1216Guillaume Martres2016-04-153-2/+27
|\ \ \ \ | |_|_|/ |/| | | Fix #1216 Desugar: vals that are desugared PatDef may need setters.
| * | | Check that #1216 is fixed.Dmitry Petrashko2016-04-142-0/+22
| | | |
| * | | Fix #1216 Desugar: vals that are desugared PatDef may need setters.Dmitry Petrashko2016-04-141-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | Setters are normally synthesised in Desugar while expanding the ValDef. If the tree is a PatDef it is being desugared into several ValDefs that may need to be desugared once again.
* | | | Merge pull request #1213 from felixmulder/topic/comment-parsing-fixDmitry Petrashko2016-04-113-4/+34
|\ \ \ \ | |/ / / |/| | | Fix issues with `enterBlock` for comment parsing
| * | | Fix issues with `enterBlock` for comment parsingFelix Mulder2016-04-113-4/+34
|/ / /
* | | Merge pull request #1151 from felixmulder/topic/wip-docstringsodersky2016-04-0811-46/+605
|\ \ \ | | | | | | | | Add support for raw docstrings in ASTs
| * | | Remove old datastructure for commentsFelix Mulder2016-04-071-7/+0
| | | |
| * | | Add commandline argument `-Ykeep-comments` to remove hardcodingFelix Mulder2016-04-073-7/+12
| | | |
| * | | Add binding between Symbol and Untyped tree in base contextFelix Mulder2016-04-076-41/+95
| | | | | | | | | | | | | | | | This commit also adds a printer for use by dottydoc.
| * | | Implement comments as attachments instead of tree membersFelix Mulder2016-04-074-19/+16
| | | |
| * | | Change tests to be based on JUnit, rename comments variableFelix Mulder2016-04-073-515/+463
| | | |
| * | | Add docstring support for types, vals, vars and defsFelix Mulder2016-04-072-15/+150
| | | |
| * | | Fix association of docstrings based on posisitionFelix Mulder2016-04-073-11/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit fixes errors that would've occurred in this situation: ``` /** Docstring 1 */ <- this one would've been chosen /** Docstring 2 */ /** Docstring 3 */ class Class ``` And this situation: ``` /** Docstring 1 */ trait Trait /** Docstring 2 */ <- this one would've been chosen ```
| * | | Add package object supportFelix Mulder2016-04-072-7/+99
| | | |
| * | | Add ability to parse nested classes/traits docstringsFelix Mulder2016-04-073-26/+85
| | | |
| * | | Fix traits w/o bodies not getting the correct docstringFelix Mulder2016-04-072-13/+38
| | | |
| * | | Add tests for classes and traitsFelix Mulder2016-04-074-4/+163
| | | |
| * | | Add initial support for raw docstrings in ASTsFelix Mulder2016-04-073-9/+41
| | | |
* | | | Merge pull request #1201 from liufengyun/i972Dmitry Petrashko2016-04-081-0/+74
|\ \ \ \ | |/ / / |/| | | Check Java classes are not used as objects
| * | | Check Java classes are not used as objectsliu fengyun2016-04-041-0/+74
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | Following code should not pass Ycheck: import java.lang.Math val myMath: Math.type = Math myMath.sqrt(3.0) id(myMath)
* | | Merge pull request #1186 from dotty-staging/fix-#1185odersky2016-04-0616-180/+380
|\ \ \ | | | | | | | | Improvements to cyclic checking, avoidance, named parameters
| * | | Domain checking for named type parametersMartin Odersky2016-03-303-10/+18
| | | | | | | | | | | | | | | | | | | | | | | | Now verifies that the named type parameters of an overriding type or class are the same as the named type parameters of an overridden type.
| * | | Base deskolemize on ApproximatingTypeMapMartin Odersky2016-03-301-88/+9
| | | |
| * | | Add ApproximatingTypeMap classMartin Odersky2016-03-301-22/+94
| | | | | | | | | | | | | | | | | | | | | | | | Also: In a TypeMap, the variance of the prefix is unchanged (was: always 0). This brings it in line with TypeAccumulator and the subtyping rules.
| * | | Fix documentation of liftIfHKMartin Odersky2016-03-301-1/+1
| | | |
| * | | Fix a case in deskolemize.Martin Odersky2016-03-301-1/+1
| | | | | | | | | | | | | | | | We should not return a ClassInfo as a value type.
| * | | Simplify widenToParentsMartin Odersky2016-03-301-4/+5
| | | | | | | | | | | | | | | | No need to form the glb.
| * | | Adapt type assignment for AppliedTypeTrees to new named paramsMartin Odersky2016-03-301-6/+4
| | | |
| * | | Test casesMartin Odersky2016-03-302-2/+52
| | | |
| * | | Don't lambda expand and/or types over named type parametersMartin Odersky2016-03-301-2/+16
| | | | | | | | | | | | | | | | | | | | Do it only if at least one of the types has unnamed parameters. This is a fundamental conflict with how we deal with intersections and unions.