English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
tag hash function
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-05-29 (18:06)
From: Jeremy Yallop <jeremy.yallop@e...>
Subject: tag hash function
Is there any kind of guarantee that given the name of a tag `T as a 
string t that

  (Obj.magic (CamlinternalOO.public_method_label t) : int)

will compute the hash code used to represent t?  Is there a better way 
to access the hash function (passing a string, not a tag)?  Of course, I 
could reimplement it myself, but I'd like something that will track any 
changes to the internal function.

I'm trying to compute hash codes in a camlp4 extension.