parent
b70d195473
commit
fc409d9262
|
@ -3,7 +3,6 @@
|
||||||
*
|
*
|
||||||
* Counts Armstrong Numbers between 1 and x
|
* Counts Armstrong Numbers between 1 and x
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <solana_sdk.h>
|
#include <solana_sdk.h>
|
||||||
|
|
||||||
extern uint64_t entrypoint(const uint8_t *input) {
|
extern uint64_t entrypoint(const uint8_t *input) {
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
* passed to it
|
* passed to it
|
||||||
*/
|
*/
|
||||||
#include <solana_sdk.h>
|
#include <solana_sdk.h>
|
||||||
|
|
||||||
#include "helper.h"
|
#include "helper.h"
|
||||||
|
|
||||||
extern uint64_t entrypoint(const uint8_t *input) {
|
extern uint64_t entrypoint(const uint8_t *input) {
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
* passed to it
|
* passed to it
|
||||||
*/
|
*/
|
||||||
#include <solana_sdk.h>
|
#include <solana_sdk.h>
|
||||||
|
|
||||||
#include "helper.h"
|
#include "helper.h"
|
||||||
|
|
||||||
void helper_function(void) {
|
void helper_function(void) {
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
* @brief Example C-based BPF program that moves funds from one account to
|
* @brief Example C-based BPF program that moves funds from one account to
|
||||||
* another
|
* another
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <solana_sdk.h>
|
#include <solana_sdk.h>
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/**
|
/**
|
||||||
* @brief test program that generates BPF PC relative call instructions
|
* @brief test program that generates BPF PC relative call instructions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <solana_sdk.h>
|
#include <solana_sdk.h>
|
||||||
|
|
||||||
void __attribute__ ((noinline)) helper() {
|
void __attribute__ ((noinline)) helper() {
|
||||||
|
|
|
@ -53,7 +53,7 @@ pub extern "C" fn entrypoint(_input: *mut u8) -> u64 {
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod test {
|
mod test {
|
||||||
use super::*;
|
use super::*;
|
||||||
// Pulls in the stubs requried for `info!()`
|
// Pulls in the stubs required for `info!()`
|
||||||
solana_sdk_bpf_test::stubs!();
|
solana_sdk_bpf_test::stubs!();
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
|
@ -85,7 +85,7 @@ pub extern "C" fn entrypoint(_input: *mut u8) -> u64 {
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod test {
|
mod test {
|
||||||
use super::*;
|
use super::*;
|
||||||
// Pulls in the stubs requried for `info!()`
|
// Pulls in the stubs required for `info!()`
|
||||||
solana_sdk_bpf_test::stubs!();
|
solana_sdk_bpf_test::stubs!();
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
|
@ -20,7 +20,7 @@ pub extern "C" fn entrypoint(_input: *mut u8) -> u64 {
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod test {
|
mod test {
|
||||||
use super::*;
|
use super::*;
|
||||||
// Pulls in the stubs requried for `info!()`
|
// Pulls in the stubs required for `info!()`
|
||||||
solana_sdk_bpf_test::stubs!();
|
solana_sdk_bpf_test::stubs!();
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
extern crate solana_sdk;
|
extern crate solana_sdk;
|
||||||
use num_derive::FromPrimitive;
|
use num_derive::FromPrimitive;
|
||||||
use num_traits::FromPrimitive;
|
use num_traits::FromPrimitive;
|
||||||
|
|
||||||
use solana_sdk::{
|
use solana_sdk::{
|
||||||
account_info::AccountInfo,
|
account_info::AccountInfo,
|
||||||
entrypoint,
|
entrypoint,
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
//! @brief Example Rust-based BPF program tests loop iteration
|
//! @brief Example Rust-based BPF program tests loop iteration
|
||||||
|
|
||||||
extern crate solana_sdk;
|
extern crate solana_sdk;
|
||||||
|
|
||||||
use solana_sdk::log::*;
|
use solana_sdk::log::*;
|
||||||
|
|
||||||
pub fn many_args(
|
pub fn many_args(
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
#![allow(unreachable_code)]
|
#![allow(unreachable_code)]
|
||||||
|
|
||||||
extern crate solana_sdk;
|
extern crate solana_sdk;
|
||||||
|
|
||||||
use solana_sdk::{
|
use solana_sdk::{
|
||||||
account_info::AccountInfo, entrypoint, entrypoint::ProgramResult, info, log::*, pubkey::Pubkey,
|
account_info::AccountInfo, entrypoint, entrypoint::ProgramResult, info, log::*, pubkey::Pubkey,
|
||||||
};
|
};
|
||||||
|
@ -65,7 +64,7 @@ fn process_instruction(
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod test {
|
mod test {
|
||||||
use super::*;
|
use super::*;
|
||||||
// Pulls in the stubs requried for `info!()`
|
// Pulls in the stubs required for `info!()`
|
||||||
solana_sdk_bpf_test::stubs!();
|
solana_sdk_bpf_test::stubs!();
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
Loading…
Reference in New Issue