-
Notifications
You must be signed in to change notification settings - Fork 1
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
Numbers #1
Comments
730d32d implements a parser that can handle numerals. It also adds a Notes:
Remaining issue:
|
Should 𒌋𒑱𒌋𒐕 be read as 10,0,11 or 10,11 or both? |
Assuming 𒌋𒑱𒌋𒐕 is 10,0,11, this should be(?) resolved by 58ffcb1. |
Should we support negative numbers, given that there was no conception of these historically? I feel a language without negatives is more in line with the spirit of SIGBOVIK. |
I'm realizing there is no way to directly encode some numbers with the grammar as it exists now: e.g. 50,1 (which I think should be 𒐐𒑱𒐕 where the 𒑱 is a delimiter, and not a true zero??) can't be directly input since 𒐐𒑱𒐕 gets parsed as 50,0,1. Do we need to find a way to overload 𒑱, or is there another character that can be used as a delimiter? Or do we say this is fine, and let the user construct 50,1 via addition (I guess this is where whitespace would have been used as a delimiter originally? but that also introduces ambiguity between consecutive numbers separated by whitespace vs one number with whitespace between digit groups...) |
Sounds good - the parser currently assumes no whitespace between tokens so we will need to add an explicit " " or WS token to the grammar rules where relevant. |
We need to parse numbers written in sexigesimal notation.
I think we should avoid parsing to decimal and back as that will run into major problems with fractions. So all of our
operators
need to function in sexigesimal notation. That should be easy enough but here's a repository for reference: https://github.com/HrushikeshPawar/Sexagesimal-Calculator.A short test suite would be useful:
𒐕 = 1
𒐕 = 60 (NB: how do we deal with unknown placevalues, or do we default to "1"?)
𒐕𒐕 = 2 (or 𒐖 = 2, *one glyph)
𒐕𒑱𒐕 = 61
𒌋𒐕 = 11
𒐕𒌋 = 70
𒐕𒌋𒐕 = 71
𒐕𒐕𒌋 = 130
The text was updated successfully, but these errors were encountered: