| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
| |
For mr. optimizer and his band of merry privates.
|
| |
|
|\ |
|
| |
| |
| |
| | |
And we'll need a separate mechanism for making internal fields public.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
workaround for inliner bug in run/t3835
see SI-5672 for the optimizer bug
tiny switches (2 cases or less) don't make sense anyway,
so this is not a big deal
the annotDepMethType.flags contained -Xexperimental,
which causes Any* to be considered as a valid return type,
before we weren't exposed to this, because the product methods
used (tiny) switches; with this change, they went back to pattern matches
in any case, the -Xexperimental was intended to turn on dependent method types,
not Any* as valid type (I can only assume), and they are now on by default
the other tests were affected by our refusal to emit tiny switches
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
detect partialfunction in cpsannotationchecker
emit apply/isDefinedAt if PF has @cps targs (applyOrElse can't be typed)
further hacky improvements to selective anf
better try/catch support in selective cps using freshly minted anonfun match
make virtpatmat resilient to scaladoc (after uncurry, don't translate matches
TODO: factor out translation all together so presentation compiler/scaladoc can skip it)
|
| |
| |
| |
| |
| |
| | |
the optimizer generates wrong bytecode for switches in arguments
virtpatmat happily emits a switch for a one-case switch, whereas -Xoldpatmat did not
this is not the focus of this test, hence the temporary workaround
|
| | | |
| \ | |
|\ \ \
| | | |
| | | |
| | | | |
'type-destructure' into develop
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Would prefer to bake a little longer, but, scala days.
More elaboration to come.
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
@viktorklang
|
| |\| | |
|
| | | | |
|
| | | | |
|
| |\ \ \
| | | | |
| | | | | |
Wip sip14 fixes
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
JVM, also adding EX.reportFailure where it makes sense
|
| | | | |
| | | | |
| | | | |
| | | | | |
same match approach as def isCompleted
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| |/ / /
| | | |
| | | |
| | | | |
JDK 1.6
|
| |/ /
|/| | |
|
| | | |
|
|\ \ \
| | |/
| |/| |
|
| | |
| | |
| | |
| | | |
This reverts commit f67a00a3cef270835369b8ab1bb57cbe8b2bd2a3.
|
| | | | |
| \ \ | |
| \ \ | |
| \ \ | |
| \ \ | |
| \ \ | |
|\ \ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | | |
'refs/pull/403/head'; commit 'refs/pull/404/head'; commit 'refs/pull/405/head' into develop
|
| | | | |/ / |
|
| | | | | | |
|
| | | |/ /
| | |/| | |
|
| |/ / /
| | | |
| | | |
| | | |
| | | |
| | | | |
the optimizer generates wrong bytecode for switches in arguments
virtpatmat happily emits a switch for a one-case switch, whereas -Xoldpatmat did not
this is not the focus of this test, hence the temporary workaround
|
| |\ \ \ |
|
| | | | | |
|
| | | | | |
|
|/ / / /
| | | |
| | | |
| | | | |
of it.
|
| | | | | |
| \ \ \ | |
| \ \ \ | |
| \ \ \ | |
| \ \ \ | |
| \ \ \ | |
|\ \ \ \ \ \ \
| | | | | | | |
| | | | | | | |
| | | | | | | | |
'refs/pull/392/head'; commit 'refs/pull/397/head' into develop
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
and implicit pimped on members. Thanks to Lukas for pointing it out!
|
| | | | | | | | |
|
| | | | | |/ /
| | | | |/| | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Re-enable testing the sensibility of comparing instances
of two case classes. In particular, warn if we detect that
the two objects inherit from different case classes. In
addition, avoid emitting misleading warnings when comparing "new C".
|
| | | |_|/ /
| | |/| | |
| | | | | |
| | | | | | |
Made the primary constructors private to prevent them from appearing in ScalaDoc.
|
| |/ / / / |
|
|\ \ \ \ \ |
|
| | \ \ \ \ | |
| | \ \ \ \ | |
| |\ \ \ \ \ \ |
|
| | | | | | | | |
|
| | | | | | | | |
|
| | | | | | | | |
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
some tests (unreachability, exhaustivity, @switch annotation checking) are still run under -Xoldpatmat,
but that will change before we go into RC mode (then the test/ partest of this commit will be reverted)
removed irrelevant dependency on patmat
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
typers&patmatvirtualizer have ad-hoc support for dropping annotations
in a way that makes the CPS plugins happy... this is not ideal,
but unless virtpatmat runs after the plugin phases, I don't see how to solve it
running virtpatmat after the CPS plugin would mean the pattern matching evaluation
cannot be captured by CPS, so it's not even desirable to move it to a later phase
- typedIf must lub annotated types
- drop selector.tpe's annotations
- drop annots in matchEnd's argument type
- deal with annots in casts synth by in virtpatmat
(drop them from type arg to asInstanceof, recover them using type ascription)
- workaround skolemize existential dropping annots
CPS is the main reason why typedMatchAnonFun is not used anymore,
and PartialFunction synthesis is moved back to uncurry (which is quite painful due to labeldefs being so broken)
we can't synth partialfunction during typer since T @cps[U] does not conform to Any,
so we can't pass it as a type arg to PartialFunction, so we can't type a cps-transformed PF
after the CPS plugin, T @cps[U] becomes ControlContext[...], which is a type we can pass
to PartialFunction
virtpatmat is now also run until right before uncurry
(so, can't use isPastTyper, although it means more or less the same thing -- we don't run after uncurry)
the main functional improvements are in the selective ANF transform
its treatment of labeldefs was broken: for example,
LabelDef L1; LabelDef L2 --> DefDef L1; L1(); DefDef L2; L2()
but this does not take into account L1 may jump over L2 to another label
since methods always return (or fail), and the ANF transform generates ValDefs
to store the result of those method calls, both L1 and L2 would always be executed
(so you would run a match with N cases N times, with each partial run starting at a later case)
also fixed a couple of weird bugs in selective anf that caused matches to be duplicated
(with the duplicate being nested in the original)
since label defs are turned into method defs, and later defs
will be nested in the flatMap calls on the controlcontext
yielded by earlier statements, we reverse the list of method
definitions, so that earlier (in the control flow sense) methods
are visible in later ones
selective CPS now generates a catch that's directly digestible by backend
|