exception MyExn of int;; exception OtherExn;; let f () = raise (MyExn 7);; try f () with MyExn x -> print_endline ("blah " ^ (string_of_int x)) | OtherExn -> print_endline "other exception";;