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

Fix decode number to integer #90

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

KaiveYoung
Copy link

Fix #33

case T_INTEGER:
lua_pushinteger(l, token->value.number);
break;;
case T_DOUBLE:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this still be named "number", as the number type is generic, and may be 32 or 64 bit?
(i.e. it's called lua_pushnumber for that reason)

@JCash
Copy link

JCash commented Dec 31, 2024

I think it'd be nice with a unit test as well, to make sure it works :)

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

Successfully merging this pull request may close these issues.

lua 5.3 to add integer
2 participants