-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
program-error: Add option to specify solana_program crate (#7112)
* program-error: Add option to specify solana_program crate Problem There are going to be a lot of issues with people seeing errors on spl_program_error derivation. When a build pulls in two version of solana_program, the macro uses `::solana_program`, which now becomes ambiguous. Summary of changes I'm not sure if this is a good idea, but this PR gives the ability to specify which version of `solana_program` to use when deriving the various traits on your error type. Borsh has this same functionality, and it's saved us when pulling in multiple versions of borsh in the SDK. Note: this PR defaults to `solana_program` instead of `::solana_program`, which might cause downstream issues. * Address feedback * Rename solana_program_crate -> solana_program * Oops, change the name everywhere
- Loading branch information
Showing
4 changed files
with
157 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters