blob: f48c9062462c6c4d277d94990126202064c6e11a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// $Id$
class Bug361Global extends Bug361Trees;
abstract class Bug361Trees: Bug361Global {
abstract class Tree {
var pos: int = 0;
}
object posAssigner {
def atPos[T <: Tree](pos: int, tree: T): T = {
tree.pos = pos; tree
}
}
def atPos[T <: Tree](pos: int)(tree: T): T = posAssigner.atPos(pos, tree);
}
|