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

lang: Fix cpi feature instructions not accounting for discriminator overrides #3376

Conversation

acheroncrypto
Copy link
Collaborator

Problem

CPI instruction discriminators do not take into account the potential discriminator overrides from the #[interface] attribute (#2728) or the new custom discriminator support via #[instruction(discriminator = <VALUE>)] (#3137):

let discriminator = gen_discriminator(SIGHASH_GLOBAL_NAMESPACE, name);

Summary of changes

  • Fix cpi feature instructions not accounting for discriminator overrides
  • Perform a small refactor to reduce cloning and code duplication of related code

Copy link

vercel bot commented Nov 20, 2024

@acheroncrypto is attempting to deploy a commit to the coral-xyz Team on Vercel.

A member of the Team first needs to authorize it.

@acheroncrypto acheroncrypto added lang fix Bug fix PR labels Nov 20, 2024
@acheroncrypto acheroncrypto merged commit 94ed4e0 into coral-xyz:master Nov 20, 2024
0 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fix PR lang
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant