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

Add file and line information to exceptions thrown from Lua #8

Open
mjanicek opened this issue Oct 8, 2016 · 1 comment
Open

Add file and line information to exceptions thrown from Lua #8

mjanicek opened this issue Oct 8, 2016 · 1 comment

Comments

@mjanicek
Copy link
Owner

mjanicek commented Oct 8, 2016

Exceptions thrown from Lua programs do not include the filename and line information as they do in PUC-Lua. E.g.:

$ rembulan
Rembulan 0.1-SNAPSHOT (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_60)
> nil + 1
attempt to perform arithmetic on a nil value
stack traceback:
   (omitted)
$ lua
Lua 5.3.3  Copyright (C) 1994-2016 Lua.org, PUC-Rio
> nil + 1
stdin:1: attempt to perform arithmetic on a nil value
stack traceback:
  (omitted)

(It's about the stdin:1 prefix of the error message.)

Debugging Lua programs is difficult without this information.

@mkarneim
Copy link

Indeed, this would be really helpful.

kroepke added a commit to kroepke/luna that referenced this issue Jun 1, 2017
the tests needed wholesale changes because of the scala stringmatcher for error messages being a bit too clever in matching

fixes mjanicek/rembulan#8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants