Skip to content

Conversation

@srinathsetty
Copy link
Collaborator

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR refactors the batch_invert function by moving it from src/spartan/ppsnark.rs to src/spartan/mod.rs, making it available as a reusable utility function across the codebase. This eliminates code duplication by replacing a local closure implementation in src/provider/ipa_pc.rs with the centralized version.

Changes:

  • Moved batch_invert and batch_invert_serial functions to src/spartan/mod.rs for reuse
  • Updated imports in src/spartan/ppsnark.rs and src/provider/ipa_pc.rs to use the centralized function
  • Simplified test module structure by removing unnecessary nesting

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/spartan/mod.rs Added batch_invert and batch_invert_serial as public utility functions with documentation
src/spartan/ppsnark.rs Removed local implementation, added import, simplified test module structure
src/provider/ipa_pc.rs Removed local closure implementation, added import of centralized function

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@srinathsetty srinathsetty merged commit 742e036 into main Jan 27, 2026
12 checks passed
@srinathsetty srinathsetty deleted the batch_invert branch January 27, 2026 18:27
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.

1 participant