[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Peter Schrammel <peter.schrammel@u...> |
| Subject: | Tree of a certain class: |
I wrote a Program:
type 'i tree =
Empty
| Item of 'i
| Section of 'i * 'i
class ['i] ctree =
object (self : 'a)
val mutable content : 'i tree = Empty
method get = content
end
class debug =
object
method debug = ()
end
class dtree =
object
inherit [#debug] ctree
end
But the compiler gives me the error:
Some type variables are unbound in this type:
class dtree :
object val mutable content : (#debug as 'a) tree method get : 'a
tree end
The method get has type #debug tree where .. is unbound
make: *** [test.cmo] Error 2
How can make trees of a certain (sub)class ? (I hope there's a simple
solution)
Regards,
Peter
--
Peter Schrammel
UniBw-Muenchen 106/2/116
85579 Neubiberg
ICQ: 5469131