Skip to content
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

Clarify homogeneous equality on lists and maps #128

Merged
merged 2 commits into from
Jun 22, 2020

Conversation

JimLarson
Copy link
Contributor

Updates spec and adds conformance tests.

Closes #127

@TristonianJones TristonianJones merged commit 85c0ecd into google:master Jun 22, 2020
@JimLarson JimLarson deleted the eq branch June 22, 2020 18:18
For `double`, all not-a-number (`NaN`) values compare equal. This is different
than the usual semantics of floating-point numbers, but it is more consistent
with the usual expectations of reflexivity, and is more compatible with the
usual notions of equality on protocol buffers.
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

Also, why not do the 'right' thing and represent 'not a number' by the existing 'not a value'/falsum/bottom concept in CEL, i.e. an error. I believe this is how CEL fixes integer overflows. You could even just make it so this only pops up when performing operations with NaN, so NaN itself is still observable from within the expression.

Copy link
Contributor

@Alfus Alfus Jun 22, 2020

Choose a reason for hiding this comment

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

Also, what is:

  • NaN < 0.0
  • NaN <= NaN
  • 0 > -0

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.

Clarify homogeneous equality on aggregates
3 participants