Registry / crypto / solana-program

solana-program

JSON →
library4.0.0rscratesunverified

Solana Program library for writing on-chain programs.

# Cargo.toml [dependencies] solana-program = "4.0.0"
INSTALL
IMPORT
SIG · SOLANA-PROGRAM
S
solana-program
cryptorustv4.0.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

process_instruction
use solana_program::entrypoint::process_instruction;

Minimal Solana program entrypoint.

use solana_program::{ account_info::AccountInfo, entrypoint, entrypoint::ProgramResult, pubkey::Pubkey, }; entrypoint!(process_instruction); fn process_instruction( _program_id: &Pubkey, _accounts: &[AccountInfo], _instruction_data: &[u8], ) -> ProgramResult { Ok(()) }
Debug
Known issues
gotchaOnly works within Solana runtime; cannot be tested without Solana tools.
fix
Use solana-program-test for local testing.
affects: >=4.0.0
Upgrade
Version history
4.0.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
14 hits · last 30 days
node
14
Resources
solana-program — cargo add solana-program · libregistry