# # Panoramix v4 Oct 2019 # Decompiled source of bsc:0x09B7E289196cdac1AB978dC0e2069FE28eCda7f9 # # Let's make the world open source # const decimals = 18 def storage: balanceOf is mapping of uint256 at storage 0 allowance is mapping of uint256 at storage 1 totalSupply is uint256 at storage 2 stor3 is array of struct at storage 3 stor4 is array of struct at storage 4 def totalSupply() payable: return totalSupply def balanceOf(address _owner) payable: require calldata.size - 4 >=′ 32 require _owner == _owner return balanceOf[addr(_owner)] def allowance(address _owner, address _spender) payable: require calldata.size - 4 >=′ 64 require _owner == _owner require _spender == _spender return allowance[addr(_owner)][addr(_spender)] # # Regular functions # def _fallback() payable: # default function revert def approve(address _spender, uint256 _value) payable: require calldata.size - 4 >=′ 64 require _spender == _spender require _value == _value if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve from the zero address' if not _spender: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve to the zero address' allowance[caller][addr(_spender)] = _value log Approval( address owner=_value, address spender=caller, uint256 value=_spender) return 1 def unknown6764765d(uint256 _param1) payable: require calldata.size - 4 >=′ 32 require _param1 == _param1 if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: burn from the zero address' if balanceOf[caller] < _param1: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: burn amount exceeds balance' balanceOf[caller] -= _param1 if totalSupply < _param1: revert with 'NH{q', 17 totalSupply -= _param1 log Transfer( address from=_param1, address to=caller, uint256 value=0) def increaseAllowance(address _spender, uint256 _addedValue) payable: require calldata.size - 4 >=′ 64 require _spender == _spender require _addedValue == _addedValue if allowance[caller][addr(_spender)] > -_addedValue - 1: revert with 'NH{q', 17 if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve from the zero address' if not _spender: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve to the zero address' allowance[caller][addr(_spender)] += _addedValue log Approval( address owner=(allowance[caller][addr(_spender)] + _addedValue), address spender=caller, uint256 value=_spender) return 1 def transfer(address _to, uint256 _value) payable: require calldata.size - 4 >=′ 64 require _to == _to require _value == _value if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer from the zero address' if not _to: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer to the zero address' if balanceOf[caller] < _value: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer amount exceeds balance' balanceOf[caller] -= _value if balanceOf[addr(_to)] > -_value - 1: revert with 'NH{q', 17 balanceOf[addr(_to)] += _value log Transfer( address from=_value, address to=caller, uint256 value=_to) return 1 def decreaseAllowance(address _spender, uint256 _subtractedValue) payable: require calldata.size - 4 >=′ 64 require _spender == _spender require _subtractedValue == _subtractedValue if allowance[caller][addr(_spender)] < _subtractedValue: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: decreased allowance below zero' if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve from the zero address' if not _spender: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve to the zero address' allowance[caller][addr(_spender)] -= _subtractedValue log Approval( address owner=(allowance[caller][addr(_spender)] - _subtractedValue), address spender=caller, uint256 value=_spender) return 1 def transferFrom(address _from, address _to, uint256 _value) payable: require calldata.size - 4 >=′ 96 require _from == _from require _to == _to require _value == _value if not _from: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer from the zero address' if not _to: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer to the zero address' if balanceOf[addr(_from)] < _value: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer amount exceeds balance' balanceOf[addr(_from)] -= _value if balanceOf[addr(_to)] > -_value - 1: revert with 'NH{q', 17 balanceOf[addr(_to)] += _value log Transfer( address from=_value, address to=_from, uint256 value=_to) if allowance[addr(_from)][caller] < _value: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: transfer amount exceeds allowance' if not _from: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve from the zero address' if not caller: revert with 0x8c379a000000000000000000000000000000000000000000000000000000000, 'ERC20: approve to the zero address' allowance[addr(_from)][caller] -= _value log Approval( address owner=(allowance[addr(_from)][caller] - _value), address spender=_from, uint256 value=caller) return 1 def name() payable: if bool(stor3.length): if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if bool(stor3.length): if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if stor3.length.field_1: if 31 < stor3.length.field_1: mem[128] = uint256(stor3.field_0) idx = 128 s = 0 while stor3.length.field_1 + 96 > idx: mem[idx + 32] = stor3[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=2 * Mask(256, -1, stor3.length.field_1), data=mem[128 len ceil32(stor3.length.field_1)]) mem[128] = 256 * stor3.length.field_8 else: if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if stor3.length.field_1: if 31 < stor3.length.field_1: mem[128] = uint256(stor3.field_0) idx = 128 s = 0 while stor3.length.field_1 + 96 > idx: mem[idx + 32] = stor3[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=2 * Mask(256, -1, stor3.length.field_1), data=mem[128 len ceil32(stor3.length.field_1)]) mem[128] = 256 * stor3.length.field_8 mem[ceil32(stor3.length.field_1) + 192 len ceil32(stor3.length.field_1)] = mem[128 len ceil32(stor3.length.field_1)] if ceil32(stor3.length.field_1) > stor3.length.field_1: mem[ceil32(stor3.length.field_1) + stor3.length.field_1 + 192] = 0 return Array(len=2 * Mask(256, -1, stor3.length.field_1), data=mem[128 len ceil32(stor3.length.field_1)], mem[(2 * ceil32(stor3.length.field_1)) + 192 len 2 * ceil32(stor3.length.field_1)]), if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if bool(stor3.length): if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if stor3.length.field_1: if 31 < stor3.length.field_1: mem[128] = uint256(stor3.field_0) idx = 128 s = 0 while stor3.length.field_1 + 96 > idx: mem[idx + 32] = stor3[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=stor3.length % 128, data=mem[128 len ceil32(stor3.length.field_1)]) mem[128] = 256 * stor3.length.field_8 else: if bool(stor3.length) == stor3.length.field_1 < 32: revert with 'NH{q', 34 if stor3.length.field_1: if 31 < stor3.length.field_1: mem[128] = uint256(stor3.field_0) idx = 128 s = 0 while stor3.length.field_1 + 96 > idx: mem[idx + 32] = stor3[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=stor3.length % 128, data=mem[128 len ceil32(stor3.length.field_1)]) mem[128] = 256 * stor3.length.field_8 mem[ceil32(stor3.length.field_1) + 192 len ceil32(stor3.length.field_1)] = mem[128 len ceil32(stor3.length.field_1)] if ceil32(stor3.length.field_1) > stor3.length.field_1: mem[ceil32(stor3.length.field_1) + stor3.length.field_1 + 192] = 0 return Array(len=stor3.length % 128, data=mem[128 len ceil32(stor3.length.field_1)], mem[(2 * ceil32(stor3.length.field_1)) + 192 len 2 * ceil32(stor3.length.field_1)]), def symbol() payable: if bool(stor4.length): if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if bool(stor4.length): if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if stor4.length.field_1: if 31 < stor4.length.field_1: mem[128] = uint256(stor4.field_0) idx = 128 s = 0 while stor4.length.field_1 + 96 > idx: mem[idx + 32] = stor4[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=2 * Mask(256, -1, stor4.length.field_1), data=mem[128 len ceil32(stor4.length.field_1)]) mem[128] = 256 * stor4.length.field_8 else: if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if stor4.length.field_1: if 31 < stor4.length.field_1: mem[128] = uint256(stor4.field_0) idx = 128 s = 0 while stor4.length.field_1 + 96 > idx: mem[idx + 32] = stor4[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=2 * Mask(256, -1, stor4.length.field_1), data=mem[128 len ceil32(stor4.length.field_1)]) mem[128] = 256 * stor4.length.field_8 mem[ceil32(stor4.length.field_1) + 192 len ceil32(stor4.length.field_1)] = mem[128 len ceil32(stor4.length.field_1)] if ceil32(stor4.length.field_1) > stor4.length.field_1: mem[ceil32(stor4.length.field_1) + stor4.length.field_1 + 192] = 0 return Array(len=2 * Mask(256, -1, stor4.length.field_1), data=mem[128 len ceil32(stor4.length.field_1)], mem[(2 * ceil32(stor4.length.field_1)) + 192 len 2 * ceil32(stor4.length.field_1)]), if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if bool(stor4.length): if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if stor4.length.field_1: if 31 < stor4.length.field_1: mem[128] = uint256(stor4.field_0) idx = 128 s = 0 while stor4.length.field_1 + 96 > idx: mem[idx + 32] = stor4[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=stor4.length % 128, data=mem[128 len ceil32(stor4.length.field_1)]) mem[128] = 256 * stor4.length.field_8 else: if bool(stor4.length) == stor4.length.field_1 < 32: revert with 'NH{q', 34 if stor4.length.field_1: if 31 < stor4.length.field_1: mem[128] = uint256(stor4.field_0) idx = 128 s = 0 while stor4.length.field_1 + 96 > idx: mem[idx + 32] = stor4[s].field_256 idx = idx + 32 s = s + 1 continue return Array(len=stor4.length % 128, data=mem[128 len ceil32(stor4.length.field_1)]) mem[128] = 256 * stor4.length.field_8 mem[ceil32(stor4.length.field_1) + 192 len ceil32(stor4.length.field_1)] = mem[128 len ceil32(stor4.length.field_1)] if ceil32(stor4.length.field_1) > stor4.length.field_1: mem[ceil32(stor4.length.field_1) + stor4.length.field_1 + 192] = 0 return Array(len=stor4.length % 128, data=mem[128 len ceil32(stor4.length.field_1)], mem[(2 * ceil32(stor4.length.field_1)) + 192 len 2 * ceil32(stor4.length.field_1)]),
0.4.18