Direct entrypoint for execution (#7746)
This commit is contained in:
@@ -113,6 +113,12 @@ pub fn next_keyed_account<I: Iterator>(iter: &mut I) -> Result<I::Item, Instruct
|
||||
iter.next().ok_or(InstructionError::NotEnoughAccountKeys)
|
||||
}
|
||||
|
||||
/// Return true if the first keyed_account is executable, used to determine if
|
||||
/// the loader should call a program's 'main'
|
||||
pub fn is_executable(keyed_accounts: &[KeyedAccount]) -> bool {
|
||||
!keyed_accounts.is_empty() && keyed_accounts[0].account.executable
|
||||
}
|
||||
|
||||
pub fn limited_deserialize<T>(data: &[u8]) -> Result<T, InstructionError>
|
||||
where
|
||||
T: serde::de::DeserializeOwned,
|
||||
|
Reference in New Issue
Block a user