Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
* OCaml 2.0
@ 1998-08-26 14:18 Vladimir Vyskocil
  1998-08-29 17:52 ` Jerome Vouillon
  1998-08-30 10:38 ` boos
  0 siblings, 2 replies; 3+ messages in thread
From: Vladimir Vyskocil @ 1998-08-26 14:18 UTC (permalink / raw)
  To: caml-list

Bonjour,

Suite a la sortie de la version 2.0 d'Objective Caml, nous nous sommes
lance dans le "portage"
de notre logiciel depuis la version 1.07 avec l'aide de ocaml1to2. Nous
avons rencontre les
problemes suivants :

- Nous avons des classes marquees closed qui posent probleme avec
Ocaml2.0, l'explication donnee
dans le fichier README de ocaml1to2 :
   <<It usually suffices to introduce coercions (self :> c) from the
        self type to a known closed class type c >>
n'est pas tres parlante pour nous, pourriez vous donner un exemple
simple ?

- Dans l'exemple suivant :

class a =
    object (self)
    method call_pipo x = x#pipo self
    end
  ;;
Some type variables are unbound in this type:
  class a : object ('a) method call_pipo : < pipo : 'a -> 'b; .. > -> 'b
end
The method call_pipo has type
  < pipo : < call_pipo : 'a; .. > -> 'b; .. > -> 'b as 'a
where 'c is unbound

Le type 'c n'apparait pas dans la signature de la classe, a quoi
correspond t'il ?

- Dans l'exemple suivant :

class a =
  object (self)
  method call_pipo (x:b) = x#pipo self
  end
and b a =
  object
  method pipo (x:a):a = x
  end;;
This expression has type < call_pipo : b -> 'a; .. >
but is here used with type 'b
Self type cannot escape its class

pourriez vous expliquer ce message d'erreur et donner une maniere de
re-ecrire cela ?

                        Merci par avance

--
Vyskocil Vladimir
vvyskoci@sophia.inria.fr
http://www.inria.fr/safir/WHOSWHO/Vladimir.html








^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1998-08-31 11:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-08-26 14:18 OCaml 2.0 Vladimir Vyskocil
1998-08-29 17:52 ` Jerome Vouillon
1998-08-30 10:38 ` boos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox