-
Notifications
You must be signed in to change notification settings - Fork 103
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
Drop support for "use math" #21
Conversation
Oh, I broke something and 262 found it! I'll take a look later. |
This one is ready @bnoordhuis ! |
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.
👍
I did have a ready-to-submit commit that removes all the #ifdef CONFIG_BIGNUM
that's probably going to conflict heavily with this. Oh well.
/* assume bigint mode: floats are parsed as integers if no decimal | ||
point nor exponent */ | ||
#define ATOD_MODE_BIGINT (1 << 9) | ||
#define ATOD_MODE_UNUSED (1 << 9) |
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.
#define ATOD_MODE_UNUSED (1 << 9) |
Or did you have a reason for keeping it around?
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.
Nah.
quickjs.c
Outdated
} else if ((atod_type == ATOD_TYPE_FLOAT64) && is_float && radix != 10) { | ||
goto fail; |
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.
} else if ((atod_type == ATOD_TYPE_FLOAT64) && is_float && radix != 10) { | |
goto fail; | |
} else if (atod_type == ATOD_TYPE_FLOAT64 && is_float && radix != 10) { | |
goto fail; |
goto fail; | ||
case JS_TAG_FLOAT64: | ||
case JS_TAG_BIG_FLOAT: | ||
goto fail; | ||
/* fall tru */ |
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.
/* fall tru */ |
quickjs.c
Outdated
if (s->cur_func->js_mode & JS_MODE_MATH) | ||
s->token.val = TOK_MATH_POW_ASSIGN; | ||
else | ||
s->token.val = TOK_XOR_ASSIGN; | ||
s->token.val = TOK_XOR_ASSIGN; |
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.
I believe you can replace this block (the code inside the #ifdef CONFIG_BIGNUM
) with just the #else
case.
Sorry I got the impression you hadn't started :-/ |
Don't worry about it, it happens. |
No description provided.