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

incomplete backtrace #4063

Closed
vicuna opened this issue Jul 17, 2006 · 1 comment
Closed

incomplete backtrace #4063

vicuna opened this issue Jul 17, 2006 · 1 comment
Labels

Comments

@vicuna
Copy link

vicuna commented Jul 17, 2006

Original bug ID: 4063
Reporter: padator
Status: closed (set by @xavierleroy on 2006-07-18T09:29:56Z)
Resolution: not a bug
Priority: normal
Severity: minor
Version: 3.09.2
Category: ~DO NOT USE (was: OCaml general)

Bug description

When I do (on the test file attached)
ocamlc -g test_bug_backtrace.ml
./a.out 1

I get only this backtrace

Fatal error: exception Failure("failwith: OneExn")
Raised at file "pervasives.ml", line 22, characters 22-33
Called from file "test_bug_backtrace.ml", line 22, characters 15-26

I would like to know that it was also called from line 12, and then
line 7.

What is wierd is that when I use ocamldebug on the same file, it
has a correct backtrace and I am able to go through all the
intermediate callers.

Additional information

This is a simple example, but on my real program,
I am in the situation where I don't know at all from where the
exception was launched.

For instance I get

Fatal error: exception Failure("not supported")
Raised at file "pervasives.ml", line 22, characters 22-33
Called from file "list.ml", line 57, characters 20-23
Called from file "list.ml", line 57, characters 20-23
Called from file "cocci.ml", line 165, characters 19-34
Called from file "main.ml", line 55, characters 8-61
Called from file "main.ml", line 106, characters 39-46

Whereas It should have added just after the "pervasives"
Called from file "asttoctl.ml", line ... characters ...
In which case I know I have to look for the file asttoctl.ml

File attachments

@vicuna
Copy link
Author

vicuna commented Jul 18, 2006

Comment author: @xavierleroy

Tail calls do not appear in backtraces. This is pretty much unavoidable
since tail calls leave no trace in the stack.

@vicuna vicuna closed this as completed Jul 18, 2006
@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