diff options
author | Martin Odersky <odersky@gmail.com> | 2006-08-22 16:20:09 +0000 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2006-08-22 16:20:09 +0000 |
commit | 9050da710809b5d9fafa577264b0e1aa61fc6ef7 (patch) | |
tree | 49f92667370f2dc78e03612ca1c925b583ff1144 /test/files/neg/bug712.scala | |
parent | dd535c3645330025d366f82f1032184b51886274 (diff) | |
download | scala-9050da710809b5d9fafa577264b0e1aa61fc6ef7.tar.gz scala-9050da710809b5d9fafa577264b0e1aa61fc6ef7.tar.bz2 scala-9050da710809b5d9fafa577264b0e1aa61fc6ef7.zip |
Fixed bugs. Generalized implicit lookup.
Diffstat (limited to 'test/files/neg/bug712.scala')
-rw-r--r-- | test/files/neg/bug712.scala | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/files/neg/bug712.scala b/test/files/neg/bug712.scala new file mode 100644 index 0000000000..0887810c85 --- /dev/null +++ b/test/files/neg/bug712.scala @@ -0,0 +1,19 @@ +trait A { + type Node <: NodeImpl; + implicit def coerce(n : NodeImpl) = n.self; + trait NodeImpl { + def self : Node; + } +} +trait B extends A { + type Parent <: ParentImpl; + implicit def coerce(p : ParentImpl) = p.self; + trait ParentImpl; + type Symbol; + trait SymbolImpl { + def scope : Int; + } + implicit def coerceSym(sym : Symbol) : SymbolImpl; + var s : Symbol = null; + val s_scope = s.scope; +} |