rolled back Constructors.scala
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@15452 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
This commit is contained in:
parent
db866bcfdd
commit
f5deeca7b6
|
@ -108,11 +108,13 @@ abstract class Constructors extends Transform {
|
||||||
def canBeMoved(tree: Tree) = tree match {
|
def canBeMoved(tree: Tree) = tree match {
|
||||||
//todo: eliminate thisRefSeen
|
//todo: eliminate thisRefSeen
|
||||||
case ValDef(mods, _, _, _) =>
|
case ValDef(mods, _, _, _) =>
|
||||||
|
/*
|
||||||
if (!(mods hasFlag PRESUPER | PARAMACCESSOR) && !thisRefSeen &&
|
if (!(mods hasFlag PRESUPER | PARAMACCESSOR) && !thisRefSeen &&
|
||||||
{ val g = tree.symbol.getter(tree.symbol.owner);
|
{ val g = tree.symbol.getter(tree.symbol.owner);
|
||||||
g != NoSymbol && !g.allOverriddenSymbols.isEmpty
|
g != NoSymbol && !g.allOverriddenSymbols.isEmpty
|
||||||
})
|
})
|
||||||
unit.warning(tree.pos, "the semantics of this definition will change; the initialization will no longer be executed before the superclass is called")
|
unit.warning(tree.pos, "the semantics of this definition will change; the initialization will no longer be executed before the superclass is called")
|
||||||
|
*/
|
||||||
(mods hasFlag PRESUPER | PARAMACCESSOR) || !thisRefSeen
|
(mods hasFlag PRESUPER | PARAMACCESSOR) || !thisRefSeen
|
||||||
case _ => false
|
case _ => false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue