summaryrefslogtreecommitdiff
path: root/test/files/pos/t3439.scala
blob: ccc75cc4cf2e1331d249813ef07ec263842d9c52 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
class Base[M](i: Int)
 
// was "implicit modifier not allowed on top level objects"
class D1()(implicit i: Int) extends Base({println(i); 0})

// what "no implicit value of type Int found"
class D2()(implicit i: Int) extends Base(implicitly[Int])


abstract class ParametricMessage[M: Manifest](msg: M) { def message = msg }
case class ParametricMessage1[M: Manifest](msg: M, p1: Class[_]) extends ParametricMessage(msg)


class Wrap {
  class Base[M](i: Int)
   
  // was "implicit modifier not allowed on top level objects"
  class D1()(implicit i: Int) extends Base({println(i); 0})

  // what "no implicit value of type Int found"
  class D2()(implicit i: Int) extends Base(implicitly[Int])


  abstract class ParametricMessage[M: Manifest](msg: M) { def message = msg }
  case class ParametricMessage1[M: Manifest](msg: M, p1: Class[_]) extends ParametricMessage(msg)
}