1// Reconstructed from the compiled program by revrsly.
2// Read from the bytecode: instruction names and discriminators; each instruction's accounts in
3// order, with the types and attributes their loaders' checks imply (◇ inferred: the error codes
4// they raise, the account type whose discriminator they compare, the program ids they compare
5// with); the program's error enum; event and account type names. `/* … */` is a value not
6// recovered. Handler bodies are the register-level logic of each instruction's own handler.
7// Argument names come from a published IDL when there is one, else they are placeholders; struct
8// fields are not recovered. This is a reconstruction, NOT the author's source, and will not
9// compile as-is.
10// Program: EPAAwc1SGWCheofexAqLVZ7jm1nk2ahrqX5pev1bMyo6 (mainnet)
11
12use anchor_lang::prelude::*;
13
14declare_id!("EPAAwc1SGWCheofexAqLVZ7jm1nk2ahrqX5pev1bMyo6");■ string · 44 B
15
16// Accounts — each instruction's accounts, in order, as its account loader (try_accounts) checks them.
17
18▸ 4 more #[derive(Accounts)] structs · lines 18–60
61
62#[derive(Accounts)]
63pub struct SetAdmin<'info> {◇ 2 accounts · order, types and checks inferred
64 pub admin: Signer<'info>,
65 #[account(mut, seeds = [b"registry"], bump)]■ string · 8 B
66 pub registry: AccountInfo<'info>,
67}
68
69▸ 2 more #[derive(Accounts)] structs · lines 69–86
87
88#[program]
89pub mod program {
90 use super::*;
91
1183
1184 // discriminator fba300345bc2bb5c● found in the code at .text+0x3cc8
1185 // arg layout: @0: Pubkey | [u8; 32]
1186 // argument names are placeholders; offsets, sizes (hence types) inferred from the handler's data reads
1187 ▾ pub fn set_admin(ctx: Context<SetAdmin>, arg_0: Pubkey) -> Result<()> {● its sha256 matches the discriminator
1188 // ◇ The program's own handler (`set_admin` in reconstructed.rs), register-level. Anchor's wrapper
1189 // (`set_admin_handler`) loads the accounts, then calls it with r1 = where its Result is written,
1190 // r2 = &Context. Calls to other fn_* are in reconstructed.rs.
1191 // 12 stack slots (local_…) used below; declared in reconstructed.rs.
1192 r7 = r2;
1193 r1 = *((r1 +