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

CtypesGen doesn't like single digit integers #62

Closed
Alan-R opened this issue Sep 5, 2018 · 1 comment
Closed

CtypesGen doesn't like single digit integers #62

Alan-R opened this issue Sep 5, 2018 · 1 comment

Comments

@Alan-R
Copy link
Collaborator

Alan-R commented Sep 5, 2018

In pplexer.py, there is the following definition:
INT_LITERAL = sub(r"(?P<p1>(?:0x{H}+)|(?:0[0-7]+)|(?:[1-9]{D}+))(?P<suf>{IS})")

This requires that octal integers consist of more than one digit, and also the same for decimal integers. The following line fixes these problems:
INT_LITERAL = sub(r"(?P<p1>(?:0x{H}+)|(?:0[0-7]*)|(?:[1-9]{D}*))(?P<suf>{IS})")

Note in both cases the replacement of a + character with a * character.

@Alan-R
Copy link
Collaborator Author

Alan-R commented Sep 2, 2019

This should be fixed now. Will reopen if it's not...

@Alan-R Alan-R closed this as completed Sep 2, 2019
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

1 participant