X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Furimanager%2FuriManager.ml;h=2d099a4e9748bf64cae26ef76bf6361ce9986821;hb=b266ed97b63400d62ab4ba6a4ebdfbc1d5b0c2bb;hp=c0da8eb4b334e5a3e01fea383fcfcc8c88879678;hpb=230b21d82131c6e6a4bccad225d5dc419aeb9ae4;p=helm.git diff --git a/helm/software/components/urimanager/uriManager.ml b/helm/software/components/urimanager/uriManager.ml index c0da8eb4b..2d099a4e9 100644 --- a/helm/software/components/urimanager/uriManager.ml +++ b/helm/software/components/urimanager/uriManager.ml @@ -191,6 +191,25 @@ let bodyuri_of_uri (uri, _) = None ;; +let ind_uri_split ((s, _) as uri) = + let noxp = strip_xpointer uri in + try + (let arg_index = String.rindex s '(' in + try + (let ty_index = String.index_from s arg_index '/' in + try + (let k_index = String.index_from s (ty_index+1) '/' in + let tyno = int_of_string (String.sub s (ty_index + 1) (k_index - ty_index - 1)) in + let kno = int_of_string (String.sub s (k_index + 1) (String.length s - k_index - 2)) in + noxp, Some tyno, Some kno) + with Not_found -> + let tyno = int_of_string (String.sub s (ty_index + 1) (String.length s - ty_index - 2)) in + noxp, Some tyno, None) + with Not_found -> noxp, None, None + ) + with Not_found -> noxp, None, None +;; + (* these are bugged! * we should remove _types, _univ, _ann all toghether *) let innertypesuri_of_uri (uri, _) =