diff options
author | Martin Odersky <odersky@gmail.com> | 2016-08-26 11:31:52 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-08-26 11:31:59 +0200 |
commit | e61ff6f4cfb632b11b7e54e2904706d382634eda (patch) | |
tree | df76b38a73dccdb52f0ebf7bb47f6e6afc989a28 /tests/pos/dependent-implicits.scala | |
parent | 910aa4b4b6b1db98148566ca0b46e026fd5e312d (diff) | |
download | dotty-e61ff6f4cfb632b11b7e54e2904706d382634eda.tar.gz dotty-e61ff6f4cfb632b11b7e54e2904706d382634eda.tar.bz2 dotty-e61ff6f4cfb632b11b7e54e2904706d382634eda.zip |
Dependent method tests
Diffstat (limited to 'tests/pos/dependent-implicits.scala')
-rw-r--r-- | tests/pos/dependent-implicits.scala | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/pos/dependent-implicits.scala b/tests/pos/dependent-implicits.scala new file mode 100644 index 000000000..17a323112 --- /dev/null +++ b/tests/pos/dependent-implicits.scala @@ -0,0 +1,7 @@ +object Test { + trait T { type X; val x: X } + implicit def f(x: T): x.X = x.x + val t = new T { type X = String; val x = "" } + val x: String = t + val uy: String = f(t) +} |