Browse Source

token[-2022]: Change `target_arch` to `target_os` (#3493)

Jon Cinque 3 years ago
parent
commit
8d6931905e
1 changed files with 2 additions and 2 deletions
  1. 2 2
      program/src/processor.rs

+ 2 - 2
program/src/processor.rs

@@ -1010,7 +1010,7 @@ impl Processor {
 /// Helper function to mostly delete an account in a test environment.  We could
 /// potentially muck around the bytes assuming that a vec is passed in, but that
 /// would be more trouble than it's worth.
-#[cfg(not(target_arch = "bpf"))]
+#[cfg(not(target_os = "solana"))]
 fn delete_account(account_info: &AccountInfo) -> Result<(), ProgramError> {
     account_info.assign(&system_program::id());
     let mut account_data = account_info.data.borrow_mut();
@@ -1020,7 +1020,7 @@ fn delete_account(account_info: &AccountInfo) -> Result<(), ProgramError> {
 }
 
 /// Helper function to totally delete an account on-chain
-#[cfg(target_arch = "bpf")]
+#[cfg(target_os = "solana")]
 fn delete_account(account_info: &AccountInfo) -> Result<(), ProgramError> {
     account_info.assign(&system_program::id());
     account_info.realloc(0, false)