Trait cashweb::secp256k1::cashweb_secp256k1_sys::CPtr[]

pub trait CPtr {
    type Target;
    pub fn as_c_ptr(&self) -> *const Self::Target;
pub fn as_mut_c_ptr(&mut self) -> *mut Self::Target; }

A trait for producing pointers that will always be valid in C. (assuming NULL pointer is a valid no-op) Rust doesn't promise what pointers does it give to ZST (https://doc.rust-lang.org/nomicon/exotic-sizes.html#zero-sized-types-zsts) In case the type is empty this trait will give a NULL pointer, which should be handled in C.

Associated Types

type Target

Loading content...

Required methods

pub fn as_c_ptr(&self) -> *const Self::Target

pub fn as_mut_c_ptr(&mut self) -> *mut Self::Target

Loading content...

Implementations on Foreign Types

impl<T> CPtr for [T]

type Target = T

Loading content...

Implementors

impl CPtr for KeyPair

type Target = u8

impl CPtr for cashweb::secp256k1::cashweb_secp256k1_sys::PublicKey

type Target = u8

impl CPtr for cashweb::secp256k1::cashweb_secp256k1_sys::Signature

type Target = u8

impl CPtr for XOnlyPublicKey

type Target = u8

impl CPtr for cashweb::secp256k1::schnorrsig::PublicKey[src]

impl CPtr for cashweb::secp256k1::schnorrsig::Signature[src]

type Target = u8

impl CPtr for Message[src]

type Target = u8

impl CPtr for cashweb::secp256k1::PublicKey[src]

type Target = PublicKey

impl CPtr for SecretKey[src]

type Target = u8

impl CPtr for cashweb::secp256k1::Signature[src]

type Target = Signature

Loading content...