Skip to content

Conversation

@IvanGoncharov
Copy link
Member

Currently astFromValue converts -1 to float, 0000 to integer and also escapes strings when it shouldn't.

ListValueNode,
ObjectValueNode,
} from '../language/ast';
import type { ValueNode } from '../language/ast';
Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for cleaning up these flow types!

* - NegativeSign? 0
* - NegativeSign? NonZeroDigit ( Digit+ )?
*/
const integerStringRegExp = /^-?(0|[1-9][0-9]*)$/;
Copy link
Contributor

Choose a reason for hiding this comment

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

Much better. Thanks for including the comment with the lexeme rule

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants