Browse thread
stack trace on exception in top-level
- Sam Steingold
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: | 2007-04-19 (19:48) |
From: | Sam Steingold <sds@g...> |
Subject: | stack trace on exception in top-level |
how do I get backtraces on exceptions in then top-level? E.g.: # let f x = invalid_arg (sprintf "error: %d" x) ;; val f : int -> 'a = <fun> # let g x = f (x+1) ;; val g : int -> 'a = <fun> # let h x = g (x+1) ;; val h : int -> 'a = <fun> # h 1;; Exception: Invalid_argument "error: 3". I want to see something like: h called g on line 1 g called f on line 1 f raised invalid_argument on line 1 thanks. Sam,