forked from solana-labs/solana-program-library
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
token-2022: Add support for Non-Transferable Tokens (NTTs) - NonTrans…
…ferableMint extension (solana-labs#3178) Co-authored-by: Juan Oxoby <me@jmoxo.by>
- Loading branch information
Showing
5 changed files
with
97 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
use { | ||
crate::extension::{Extension, ExtensionType}, | ||
bytemuck::{Pod, Zeroable}, | ||
}; | ||
|
||
/// Indicates that the tokens from this mint can't be transfered | ||
#[derive(Clone, Copy, Debug, Default, PartialEq, Pod, Zeroable)] | ||
#[repr(transparent)] | ||
pub struct NonTransferable; | ||
|
||
impl Extension for NonTransferable { | ||
const TYPE: ExtensionType = ExtensionType::NonTransferable; | ||
} |
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