Skip to main content

check_executable

Function check_executable 

Source
pub fn check_executable(account: &AccountView) -> ProgramResult
Expand description

Verify the account is an executable program.

Use this when an instruction receives a program account as a parameter (e.g. for a CPI target) and you want to confirm it actually is one. Anchor has an executable constraint; this is the zero-copy equivalent.