瀏覽代碼

show detailed Failure information only if OCAMLRUNPARAM = "b"

Simon Krajewski 12 年之前
父節點
當前提交
427e309cb9
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      main.ml

+ 2 - 0
main.ml

@@ -1260,6 +1260,8 @@ with
 		error ctx ("Error: " ^ msg) Ast.null_pos
 	| Arg.Help msg ->
 		message ctx msg Ast.null_pos
+	| Failure msg when (try Sys.getenv "OCAMLRUNPARAM" <> "b" with _ -> true) ->
+		message ctx msg Ast.null_pos
 	| Typer.DisplayFields fields ->
 		let ctx = print_context() in
 		let fields = List.map (fun (name,t,doc) -> name, s_type ctx t, (match doc with None -> "" | Some d -> d)) fields in