Skip to content

Commit ef92ca0

Browse files
authored
interface: Add no_std attribute (#42)
* Update dependencies * Add nostd attribute * Use nostd panic handler
1 parent 4c46748 commit ef92ca0

File tree

4 files changed

+12
-10
lines changed

4 files changed

+12
-10
lines changed

Cargo.lock

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

interface/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ crate-type = ["rlib"]
1313

1414
[dependencies]
1515
pinocchio = "0.8"
16-
pinocchio-pubkey = "0.2"
16+
pinocchio-pubkey = "0.2.4"
1717

1818
[dev-dependencies]
1919
strum = "0.27"

interface/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#![no_std]
2+
13
pub mod error;
24
pub mod instruction;
35
pub mod native_mint;

p-token/src/entrypoint.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use {
22
crate::processor::*,
33
pinocchio::{
44
account_info::AccountInfo,
5-
default_panic_handler, no_allocator, program_entrypoint,
5+
no_allocator, nostd_panic_handler, program_entrypoint,
66
program_error::{ProgramError, ToStr},
77
pubkey::Pubkey,
88
ProgramResult,
@@ -13,8 +13,8 @@ use {
1313
program_entrypoint!(process_instruction);
1414
// Do not allocate memory.
1515
no_allocator!();
16-
// Use the default panic handler.
17-
default_panic_handler!();
16+
// Use the no_std panic handler.
17+
nostd_panic_handler!();
1818

1919
/// Log an error.
2020
#[cold]

0 commit comments

Comments
 (0)