Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

line number in exception history #3809

Closed
vicuna opened this issue Oct 11, 2005 · 2 comments
Closed

line number in exception history #3809

vicuna opened this issue Oct 11, 2005 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Oct 11, 2005

Original bug ID: 3809
Reporter: administrator
Status: closed
Resolution: fixed
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)

Bug description

Full_Name: Eijiro Sumii
Version: 3.08.4 and CVS
OS: Linux
Submission from: qube3.kb.ecei.tohoku.ac.jp (130.34.188.204)

OCaml 3.08.4 seems to report wrong line numbers in exception histories. (I
asked the same question in caml-list; I interpret the silence as a proof that it
is indeed a bug.:-) The CVS version fails in an even more strange way - can I
assume that some work is underway?

Thanks.

cat main.ml
let f () = ()

let test () =
try
Bar.barFunction (-10)
with e -> raise e

let g y = y + 1

let () =
f ();
let ret = test () in
print_int (ret + 100)

cat bar.ml
let barFunction x =
let y = x + 1 in
Foo.fooFunction y
cat foo.ml
let fooFunction x =
if x > 0 then x - 1
else raise (invalid_arg "Give me a positive!")
ocamlc -g foo.ml bar.ml main.ml -o test
env OCAMLRUNPARAM=b ./test
Fatal error: exception Invalid_argument("Give me a positive!")
Raised at file "pervasives.ml", line 22, character 17
Re-raised at file "foo.ml", line 3, character 45
Called from file "main.ml", line 5, character 24
Re-raised at file "main.ml", line 1, character 11
Called from file "main.ml", line 13, character 1

@vicuna
Copy link
Author

vicuna commented Oct 25, 2005

Comment author: administrator

Hello,

Full_Name: Eijiro Sumii
Version: 3.08.4 and CVS
OS: Linux
Submission from: qube3.kb.ecei.tohoku.ac.jp (130.34.188.204)

OCaml 3.08.4 seems to report wrong line numbers in exception histories.

Thanks for reporting this bug. It will be fixed in 3.09.

-- Damien

@vicuna
Copy link
Author

vicuna commented Oct 25, 2005

Comment author: administrator

fixed in 3.09 branch -DD 2005-10-25

@vicuna vicuna closed this as completed Oct 25, 2005
@vicuna vicuna added the bug label Mar 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant