DECOMPILED SOLIDITY (Heimdall)
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;
/// @title Decompiled Contract
/// @author Jonathan Becker <jonathan@jbecker.dev>
/// @custom:version heimdall-rs v0.9.2
///
/// @notice This contract was decompiled using the heimdall-rs decompiler.
/// It was generated directly by tracing the EVM opcodes from this contract.
/// As a result, it may not compile or even be valid solidity code.
/// Despite this, it should be obvious what each function does. Overall
/// logic should have been preserved throughout decompiling.
///
/// @custom:github You can find the open-source decompiler here:
/// https://heimdall.rs
contract DecompiledContract {
uint256 public constant unresolved_30adf81f = 49955707469362902507454157297736832118868343942642399513960811609542965143241;
uint256 public INDEX;
bytes32 store_v;
uint256 public unresolved_3644e515;
mapping(bytes32 => bytes32) storage_map_h;
mapping(bytes32 => bytes32) storage_map_a;
mapping(bytes32 => bytes32) storage_map_q;
bool public decimals;
mapping(bytes32 => bytes32) storage_map_j;
uint256 public unresolved_18160ddd;
mapping(bytes32 => bytes32) storage_map_k;
address public manager;
bytes32 store_e;
mapping(bytes32 => bytes32) storage_map_p;
address public initializer;
address public stakingContract;
mapping(bytes32 => bytes32) storage_map_m;
address store_s;
mapping(bytes32 => bytes32) storage_map_l;
bytes32 store_i;
mapping(bytes32 => bytes32) storage_map_n;
bytes32 store_t;
mapping(bytes32 => bytes32) storage_map_u;
mapping(bytes32 => bytes32) storage_map_o;
event LogStakingContractUpdated(address);
event Event_8c5be1e5();
event Transfer(address, address, uint256);
event LogRebase(uint256, uint256, uint256);
event LogSupply(uint256, uint256, uint256);
event OwnershipPulled(address, address);
event OwnershipPushed(address, address);
/// @custom:selector 0x095ea7b3
/// @custom:signature Unresolved_095ea7b3(address arg0, uint256 arg1) public payable returns (bool)
/// @param arg0 ["address", "uint160", "bytes20", "int160"]
/// @param arg1 ["uint256", "bytes32", "int256"]
function Unresolved_095ea7b3(address arg0, uint256 arg1) public payable returns (bool) {
var_a = address(arg0);
storage_map_a[var_a] = arg1;
emit Event_8c5be1e5(address(msg.sender), address(arg0), arg1);
return 0x01;
}
/// @custom:selector 0x40a5737f
/// @custom:signature setIndex(uint256 arg0) public payable returns (bool)
/// @param arg0 ["uint256", "bytes32", "int256"]
function setIndex(uint256 arg0) public payable returns (bool) {
require(address(manager / 0x01) == (address(msg.sender)), "Ownable: caller is not the owner");
require(INDEX == 0);
require(!(arg0 == 0), "SafeMath: multiplication overflow");
require(arg0, "SafeMath: multiplication overflow");
require(((arg0 * store_e) / arg0) == store_e, "SafeMath: multiplication overflow");
INDEX = arg0 * store_e;
return 0x01;
INDEX = 0;
return 0x01;
}
/// @custom:selector 0xc4d66de8
/// @custom:signature initialize(address arg0) public payable returns (bool)
/// @param arg0 ["address", "uint160", "bytes20", "int160"]
function initialize(address arg0) public payable returns (bool) {
require(address(msg.sender) == (address(initializer / 0x01)));
require(!(address(arg0)) == 0);
stakingContract = (address(arg0) * 0x01) | (uint96(stakingContract));
require(0x11c37937e08000);
address var_a = address(stakingContract / 0x01);
storage_map_a[var_a] = 0xfffffffffffffffffffffffffffffffffffffffffffffffffff1c2d3019e0000;
emit Transfer(0, address(stakingContract / 0x01), unresolved_18160ddd);
emit LogStakingContractUpdated(address(arg0));
initializer = 0 | (uint96(initializer));
return 0x01;
}
/// @custom:selector 0xa9059cbb
/// @custom:signature transfer(address arg0, uint256 arg1) public payable returns (bool)
/// @param arg0 ["address", "uint160", "bytes20", "int160"]
/// @param arg1 ["uint256", "bytes32", "int256"]
function transfer(address arg0, uint256 arg1) public payable returns (bool) {
require(!(arg1 == 0), "SafeMath: multiplication overflow");
require(arg1, "SafeMath: multiplication overflow");
require(((arg1 * store_e) / arg1) == store_e, "SafeMath: multiplication overflow");
address var_f = address(msg.sender);
uint256 var_c = 0x40 + var_c;
require(!((arg1 * store_e) > storage_map_h[var_f]), "