Skip to content

Conversation

@ivokub
Copy link
Collaborator

@ivokub ivokub commented Jul 16, 2024

Description

This method allows to check for non-membership. In case we need to assert membership it is still more efficient to use AssertIsOnG2 as then we don't have to call IsZero for non-native elements which is more expensive that AssertIsEqual.

@yelhousni - can you recommend better naming for the methods? I think this could generalize to other curves, but right now needed for Linea, so omitted the implementation.

Type of change

  • New feature (non-breaking change which adds functionality)

How has this been tested?

  • TestIsOnTwistSolve
  • TestIsOnG2Solve

Checklist:

  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • I did not modify files generated from templates
  • golangci-lint does not output errors locally
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@ivokub ivokub added the type: consolidate strengthen an existing feature label Jul 16, 2024
@ivokub ivokub requested a review from yelhousni July 16, 2024 13:56
@ivokub ivokub self-assigned this Jul 16, 2024
Copy link
Contributor

@yelhousni yelhousni left a comment

Choose a reason for hiding this comment

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

LGTM

@ivokub ivokub merged commit 1453c00 into master Jul 16, 2024
@ivokub ivokub deleted the feat/bn254-nonmembership branch July 16, 2024 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: consolidate strengthen an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants