-
Notifications
You must be signed in to change notification settings - Fork 9
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
Feature/567 number encodings #596
Conversation
… numbers in a dl-program
Merge remote-tracking branch 'origin/main' into feature/567-number-encodings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good overall, apart from the small issues above.
Aside from those, I would also like to see an integration test, i.e. a new test case in the nemo/resources/testcases directory, which (1) tests parsing such numbers from facts and (2) and adds to the test case arithmetic/builtin for the extension to the conversion to i64 builtin.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, thanks :)
This enables reading of binary (
0b
), octal (0o
) and hexadecimal (0x
) encodings in the facts and rules of a program.The decoding of imported facts is not supported.
Encoded numbers that exceed the size of
i64
are decoded intobigint
and then handled as strings with iri-typexsd:integer
.closes #567.