Skip to content

Validate each tuple literal#2925

Merged
chriseth merged 2 commits intodevelopfrom
tuple-value-check
Oct 18, 2017
Merged

Validate each tuple literal#2925
chriseth merged 2 commits intodevelopfrom
tuple-value-check

Conversation

@axic
Copy link
Contributor

@axic axic commented Sep 18, 2017

Fixes #2913.

@axic axic force-pushed the tuple-value-check branch from de0093a to 336ec10 Compare September 19, 2017 07:34
@chriseth
Copy link
Contributor

We cannot check each tuple element, because in intermediate expressions, rational numbers are allowed to be outside of the valid range. Since each parenthesized expression is a tuple (violating the A part in AST), we can only do that for actual tuples, and even that is not the best solution. Ideally, we only check at the point where we go from rational number or rational number inside tuple to non-rational number.

@axic
Copy link
Contributor Author

axic commented Oct 17, 2017

Yep, we discussed this. I started moving this to expression visitor, but ran into issues. I can push the half baked code.

@chriseth
Copy link
Contributor

@axic I would say the current state of the PR is still an acceptable solution. What do you think?

@axic
Copy link
Contributor Author

axic commented Oct 18, 2017

I see now the changes. I cannot accept it since I've created the PR.

@chriseth chriseth merged commit e854da1 into develop Oct 18, 2017
@axic axic deleted the tuple-value-check branch October 18, 2017 10:01
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

Successfully merging this pull request may close these issues.

2 participants