From: Stefano Zacchiroli Date: Mon, 2 Dec 2002 15:27:33 +0000 (+0000) Subject: - bugfix: wrap Not_found exception with Stylesheet_not_found exception X-Git-Tag: V_0_0_6~18 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=4d5a5953c4ef826e1a0628ceed1a892f3e1aa104;p=helm.git - bugfix: wrap Not_found exception with Stylesheet_not_found exception when trying to apply an unloaded stylesheet --- diff --git a/helm/uwobo/src/ocaml/uwobo_styles.ml b/helm/uwobo/src/ocaml/uwobo_styles.ml index b40298780..218da1786 100644 --- a/helm/uwobo/src/ocaml/uwobo_styles.ml +++ b/helm/uwobo/src/ocaml/uwobo_styles.ml @@ -50,7 +50,9 @@ class styles = List.fold_left (fun collected_styles key -> let (key, stylesheet) = - List.find (fun (k, _) -> k = key) stylesheets + try + List.find (fun (k, _) -> k = key) stylesheets + with Not_found -> raise (Stylesheet_not_found key) in (key, Gdome_xslt.processStylesheet stylesheet)::collected_styles) []