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

Support Lua programming language #219

Open
ligurio opened this issue May 2, 2024 · 0 comments
Open

Support Lua programming language #219

ligurio opened this issue May 2, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@ligurio
Copy link

ligurio commented May 2, 2024

It would be useful to support Lua programming language in CASR the same way as Python (casr-python) and Javascript (casr-js) programming languages.

On an unhandled error, Lua generates a traceback like below:

LuaJIT:

[0] ~/sources$ luajit -e "error('crash')"
luajit: (command line):1: crash
stack traceback:
        [C]: in function 'error'
        (command line):1: in main chunk
        [C]: at 0x63a219b032e0

Lua:

[0] ~/sources$ lua -e "error('crash')"
lua: (command line):1: crash
stack traceback:
        [C]: in function 'error'
        (command line):1: in main chunk
        [C]: in ?
[0] ~/sources$ 

Manually traceback can be generated with debug.traceback("message") 1, error("message") 2, see 3.

Footnotes

  1. https://www.lua.org/manual/5.4/manual.html#pdf-debug.traceback

  2. https://www.lua.org/manual/5.4/manual.html#pdf-error

  3. https://www.lua.org/pil/8.5.html

@SweetVishnya SweetVishnya added help wanted Extra attention is needed enhancement New feature or request labels May 2, 2024
@hkctkuy hkctkuy self-assigned this Jun 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants