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

Engine: Use enum and variant svalues' enum and variant s rank #5068

Merged
merged 1 commit into from
Mar 18, 2020

Conversation

remyhaemmerle-da
Copy link
Collaborator

@remyhaemmerle-da remyhaemmerle-da commented Mar 18, 2020

In this PR, we use the rank recently (see #5048) introduced in the enum and variant svalues for:

  • pattern matching
  • value hashCode
  • value ordering (so the ordering matches the DAML-LF spec)
  • value equality

This PR advances the state of #2256

Pull Request Checklist

  • Read and understand the contribution guidelines
  • Include appropriate tests
  • Set a descriptive title and thorough description
  • Add a reference to the issue this PR will solve, if appropriate
  • Include changelog additions in one or more commit message bodies between the CHANGELOG_BEGIN and CHANGELOG_END tags
  • Normal production system change, include purpose of change in description

NOTE: CI is not automatically run on non-members pull-requests for security
reasons. The reviewer will have to comment with /AzurePipelines run to
trigger the build.

@remyhaemmerle-da remyhaemmerle-da added the component/daml-engine DAML-LF Engine & Interpreter label Mar 18, 2020
@remyhaemmerle-da remyhaemmerle-da added this to the Maintenance milestone Mar 18, 2020
CHANGELOG_BEGIN
CHANGELOG_END

We use the rank recently introduced in the enum and variant svalues for:
* pattern matchin
* value hashCode
* value ordering (so the oredering match the DAML-LF spec)
* value equality
Copy link
Contributor

@cocreature cocreature left a comment

Choose a reason for hiding this comment

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

Looks great, thanks a lot!

@remyhaemmerle-da remyhaemmerle-da merged commit 3cbba8a into master Mar 18, 2020
@remyhaemmerle-da remyhaemmerle-da deleted the speedy-enum-variant-rank branch March 18, 2020 19:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/daml-engine DAML-LF Engine & Interpreter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants