bsc/core/systemcontracts/pascal/chapel/GovTokenContract
Ethan 8c1acb0b22
feat: add pascal hardfork (#2692)
* feat: add pascal hardfork
* config: fix default value for PascalTime and add OverridePascal (#2693)
* chores: rename some contract name
* feat: update bytecode on dev env
2024-09-23 16:17:06 +08:00

1 line
19 KiB
Plaintext

608060405234801561001057600080fd5b50600436106101f05760003560e01c806370a082311161010f5780639ab24eb0116100a2578063d505accf11610071578063d505accf14610479578063dd62ed3e1461048c578063e5ed5b1e1461049f578063f1127ed8146104b257600080fd5b80639ab24eb01461042d578063a457c2d714610440578063a9059cbb14610453578063c3cda5201461046657600080fd5b806384b0196e116100de57806384b0196e146103d85780638e539e8c146103f357806391ddadf41461040657806395d89b411461042557600080fd5b806370a082311461038657806379cc6790146103af5780637ecebe00146103bd5780638129fc1c146103d057600080fd5b806339509351116101875780634bf5d7e9116101565780634bf5d7e9146102ff578063587cde1e146103075780635c19a95c1461034b5780636fcfff451461035e57600080fd5b806339509351146102b35780633a46b1a8146102c657806342966c68146102d957806344840775146102ec57600080fd5b806323b872dd116101c357806323b872dd146102745780633041949b14610287578063313ce5671461029c5780633644e515146102ab57600080fd5b8063039c91fc146101f557806306fdde0314610234578063095ea7b31461024957806318160ddd1461026c575b600080fd5b61022161020336600461209b565b61013060209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b61023c6104ef565b60405161022b9190612114565b61025c610257366004612127565b610581565b604051901515815260200161022b565b603554610221565b61025c610282366004612151565b61059b565b61029a61029536600461209b565b6105bf565b005b6040516012815260200161022b565b6102216105f8565b61025c6102c1366004612127565b610607565b6102216102d4366004612127565b610629565b61029a6102e736600461218d565b6106ae565b61029a6102fa3660046121a6565b6106c7565b61023c610740565b61033361031536600461222a565b6001600160a01b03908116600090815260fe60205260409020541690565b6040516001600160a01b03909116815260200161022b565b61029a61035936600461222a565b6107d8565b61037161036c36600461222a565b6107e5565b60405163ffffffff909116815260200161022b565b61022161039436600461222a565b6001600160a01b031660009081526033602052604090205490565b61029a6102e7366004612127565b6102216103cb36600461222a565b610807565b61029a610825565b6103e0610a05565b60405161022b9796959493929190612245565b61022161040136600461218d565b610aa3565b61040e610b0b565b60405165ffffffffffff909116815260200161022b565b61023c610b16565b61022161043b36600461222a565b610b25565b61025c61044e366004612127565b610ba7565b61025c610461366004612127565b610c22565b61029a6104743660046122ec565b610c30565b61029a610487366004612344565b610d66565b61022161049a36600461209b565b610eca565b61029a6104ad36600461209b565b610ef5565b6104c56104c03660046123ae565b610f25565b60408051825163ffffffff1681526020928301516001600160e01b0316928101929092520161022b565b6060603680546104fe906123ee565b80601f016020809104026020016040519081016040528092919081815260200182805461052a906123ee565b80156105775780601f1061054c57610100808354040283529160200191610577565b820191906000526020600020905b81548152906001019060200180831161055a57829003601f168201915b5050505050905090565b60003361058f818585610fa9565b60019150505b92915050565b6000336105a9858285610fc2565b6105b485858561103c565b506001949350505050565b33612002146105ea57604051630f22c43960e41b815261200260048201526024015b60405180910390fd5b6105f48282611055565b5050565b6000610602611185565b905090565b60003361058f81858561061a8383610eca565b6106249190612438565b610fa9565b6000610633610b0b565b65ffffffffffff1682106106855760405162461bcd60e51b815260206004820152601960248201527804552433230566f7465733a20667574757265206c6f6f6b757603c1b60448201526064016105e1565b6001600160a01b038316600090815260ff602052604090206106a7908361118f565b9392505050565b60405163e5d8776760e01b815260040160405180910390fd5b33612002146106ed57604051630f22c43960e41b815261200260048201526024016105e1565b8160005b818110156107395761072985858381811061070e5761070e61244b565b9050602002016020810190610723919061222a565b84611055565b61073281612461565b90506106f1565b5050505050565b60604361074b610b0b565b65ffffffffffff16146107a05760405162461bcd60e51b815260206004820152601d60248201527f4552433230566f7465733a2062726f6b656e20636c6f636b206d6f646500000060448201526064016105e1565b5060408051808201909152601d81527f6d6f64653d626c6f636b6e756d6265722666726f6d3d64656661756c74000000602082015290565b6107e23382611278565b50565b6001600160a01b038116600090815260ff6020526040812054610595906112f2565b6001600160a01b038116600090815260cb6020526040812054610595565b600054610100900460ff16158080156108455750600054600160ff909116105b8061085f5750303b15801561085f575060005460ff166001145b6108c25760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016105e1565b6000805460ff1916600117905580156108e5576000805461ff0019166101001790555b3341146109055760405163022d8c9560e31b815260040160405180910390fd5b3a15610924576040516383f1b1d360e01b815260040160405180910390fd5b610978604051806040016040528060148152602001732129a19023b7bb32b93730b731b2902a37b5b2b760611b8152506040518060400160405280600681526020016533b7bb21272160d11b81525061135b565b61098061138c565b6109b5604051806040016040528060148152602001732129a19023b7bb32b93730b731b2902a37b5b2b760611b8152506113b5565b6109bd61138c565b80156107e2576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b6000606080600080600060606097546000801b148015610a255750609854155b610a695760405162461bcd60e51b81526020600482015260156024820152741152540dcc4c8e88155b9a5b9a5d1a585b1a5e9959605a1b60448201526064016105e1565b610a716113ff565b610a7961140e565b60408051600080825260208201909252600f60f81b9b939a50919850469750309650945092509050565b6000610aad610b0b565b65ffffffffffff168210610aff5760405162461bcd60e51b815260206004820152601960248201527804552433230566f7465733a20667574757265206c6f6f6b757603c1b60448201526064016105e1565b6105956101008361118f565b60006106024361141d565b6060603780546104fe906123ee565b6001600160a01b038116600090815260ff60205260408120548015610b94576001600160a01b038316600090815260ff6020526040902080546000198301908110610b7257610b7261244b565b60009182526020909120015464010000000090046001600160e01b0316610b97565b60005b6001600160e01b03169392505050565b60003381610bb58286610eca565b905083811015610c155760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016105e1565b6105b48286868403610fa9565b60003361058f81858561103c565b83421115610c805760405162461bcd60e51b815260206004820152601d60248201527f4552433230566f7465733a207369676e6174757265206578706972656400000060448201526064016105e1565b604080517fe48329057bfd03d55e49b547132e39cffd9c1820ad7b9d4c5307691425d15adf60208201526001600160a01b038816918101919091526060810186905260808101859052600090610cfa90610cf29060a00160405160208183030381529060405280519060200120611484565b8585856114b1565b9050610d05816114d9565b8614610d535760405162461bcd60e51b815260206004820152601960248201527f4552433230566f7465733a20696e76616c6964206e6f6e63650000000000000060448201526064016105e1565b610d5d8188611278565b50505050505050565b83421115610db65760405162461bcd60e51b815260206004820152601d60248201527f45524332305065726d69743a206578706972656420646561646c696e6500000060448201526064016105e1565b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9888888610de58c6114d9565b6040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810186905260e0016040516020818303038152906040528051906020012090506000610e4082611484565b90506000610e50828787876114b1565b9050896001600160a01b0316816001600160a01b031614610eb35760405162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e6174757265000060448201526064016105e1565b610ebe8a8a8a610fa9565b50505050505050505050565b6001600160a01b03918216600090815260346020908152604080832093909416825291909152205490565b3361200214610f1b57604051630f22c43960e41b815261200260048201526024016105e1565b6105f48282611278565b60408051808201909152600080825260208201526001600160a01b038316600090815260ff60205260409020805463ffffffff8416908110610f6957610f6961244b565b60009182526020918290206040805180820190915291015463ffffffff8116825264010000000090046001600160e01b0316918101919091529392505050565b604051632028747160e01b815260040160405180910390fd5b6000610fce8484610eca565b9050600019811461103657818110156110295760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016105e1565b6110368484848403610fa9565b50505050565b604051638cd22d1960e01b815260040160405180910390fd5b604051630913db4760e01b81526001600160a01b03828116600483015260009190841690630913db4790602401602060405180830381865afa15801561109f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110c39190612490565b6001600160a01b03808516600090815261013060209081526040808320938716835292905220549091508181101561113c57600061110182846124a9565b6001600160a01b0380871660009081526101306020908152604080832093891683529290522084905590506111368482611501565b50611036565b8181111561103657600061115083836124a9565b6001600160a01b038087166000908152610130602090815260408083209389168352929052208490559050610739848261150b565b6000610602611515565b8154600090818160058111156111e95760006111aa84611589565b6111b490856124a9565b600088815260209020909150869082015463ffffffff1611156111d9578091506111e7565b6111e4816001612438565b92505b505b808210156112365760006111fd8383611671565b600088815260209020909150869082015463ffffffff16111561122257809150611230565b61122d816001612438565b92505b506111e9565b8015611262576000868152602090208101600019015464010000000090046001600160e01b0316611265565b60005b6001600160e01b03169695505050505050565b6001600160a01b03828116600081815260fe6020818152604080842080546033845282862054949093528787166001600160a01b03198416811790915590519190951694919391928592917f3134e8a2e6d97e929a7e54011ea5485d7d196dd5f0ba4d4ef95803e8e3fc257f9190a461103682848361168c565b600063ffffffff8211156113575760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203360448201526532206269747360d01b60648201526084016105e1565b5090565b600054610100900460ff166113825760405162461bcd60e51b81526004016105e1906124bc565b6105f482826117ca565b600054610100900460ff166113b35760405162461bcd60e51b81526004016105e1906124bc565b565b600054610100900460ff166113dc5760405162461bcd60e51b81526004016105e1906124bc565b6107e281604051806040016040528060018152602001603160f81b81525061180a565b6060609980546104fe906123ee565b6060609a80546104fe906123ee565b600065ffffffffffff8211156113575760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203460448201526538206269747360d01b60648201526084016105e1565b6000610595611491611185565b8360405161190160f01b8152600281019290925260228201526042902090565b60008060006114c287878787611859565b915091506114cf8161191d565b5095945050505050565b6001600160a01b038116600090815260cb602052604090208054600181018255905b50919050565b6105f48282611a67565b6105f48282611af2565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f611540611b0b565b611548611b64565b60408051602081019490945283019190915260608201524660808201523060a082015260c00160405160208183030381529060405280519060200120905090565b60008160000361159b57506000919050565b600060016115a884611b95565b901c6001901b905060018184816115c1576115c1612507565b048201901c905060018184816115d9576115d9612507565b048201901c905060018184816115f1576115f1612507565b048201901c9050600181848161160957611609612507565b048201901c9050600181848161162157611621612507565b048201901c9050600181848161163957611639612507565b048201901c9050600181848161165157611651612507565b048201901c90506106a78182858161166b5761166b612507565b04611c29565b6000611680600284841861251d565b6106a790848416612438565b816001600160a01b0316836001600160a01b0316141580156116ae5750600081115b156117c5576001600160a01b0383161561173c576001600160a01b038316600090815260ff6020526040812081906116e990611c3f85611c4b565b91509150846001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a7248383604051611731929190918252602082015260400190565b60405180910390a250505b6001600160a01b038216156117c5576001600160a01b038216600090815260ff60205260408120819061177290611dc085611c4b565b91509150836001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a72483836040516117ba929190918252602082015260400190565b60405180910390a250505b505050565b600054610100900460ff166117f15760405162461bcd60e51b81526004016105e1906124bc565b60366117fd838261258d565b5060376117c5828261258d565b600054610100900460ff166118315760405162461bcd60e51b81526004016105e1906124bc565b609961183d838261258d565b50609a61184a828261258d565b50506000609781905560985550565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156118905750600090506003611914565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156118e4573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661190d57600060019250925050611914565b9150600090505b94509492505050565b60008160048111156119315761193161264d565b036119395750565b600181600481111561194d5761194d61264d565b0361199a5760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016105e1565b60028160048111156119ae576119ae61264d565b036119fb5760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016105e1565b6003816004811115611a0f57611a0f61264d565b036107e25760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016105e1565b611a718282611dcc565b6035546001600160e01b031015611ae35760405162461bcd60e51b815260206004820152603060248201527f4552433230566f7465733a20746f74616c20737570706c79207269736b73206f60448201526f766572666c6f77696e6720766f74657360801b60648201526084016105e1565b611036610100611dc083611c4b565b611afc8282611e95565b611036610100611c3f83611c4b565b600080611b166113ff565b805190915015611b2d578051602090910120919050565b6097548015611b3c5792915050565b7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4709250505090565b600080611b6f61140e565b805190915015611b86578051602090910120919050565b6098548015611b3c5792915050565b600080608083901c15611baa57608092831c92015b604083901c15611bbc57604092831c92015b602083901c15611bce57602092831c92015b601083901c15611be057601092831c92015b600883901c15611bf257600892831c92015b600483901c15611c0457600492831c92015b600283901c15611c1657600292831c92015b600183901c156105955760010192915050565b6000818310611c3857816106a7565b5090919050565b60006106a782846124a9565b82546000908190818115611c985760008781526020902082016000190160408051808201909152905463ffffffff8116825264010000000090046001600160e01b03166020820152611cad565b60408051808201909152600080825260208201525b905080602001516001600160e01b03169350611ccd84868863ffffffff16565b9250600082118015611cf75750611ce2610b0b565b65ffffffffffff16816000015163ffffffff16145b15611d3c57611d0583611fd0565b60008881526020902083016000190180546001600160e01b03929092166401000000000263ffffffff909216919091179055611db6565b866040518060400160405280611d60611d53610b0b565b65ffffffffffff166112f2565b63ffffffff168152602001611d7486611fd0565b6001600160e01b0390811690915282546001810184556000938452602093849020835194909301519091166401000000000263ffffffff909316929092179101555b5050935093915050565b60006106a78284612438565b6001600160a01b038216611e225760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016105e1565b8060356000828254611e349190612438565b90915550506001600160a01b0382166000818152603360209081526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36105f460008383612039565b6001600160a01b038216611ef55760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016105e1565b6001600160a01b03821660009081526033602052604090205481811015611f695760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b60648201526084016105e1565b6001600160a01b03831660008181526033602090815260408083208686039055603580548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36117c583600084612039565b60006001600160e01b038211156113575760405162461bcd60e51b815260206004820152602760248201527f53616665436173743a2076616c756520646f65736e27742066697420696e20326044820152663234206269747360c81b60648201526084016105e1565b6117c58383836001600160a01b03808416600090815260fe60205260409020546117c591166001600160a01b03808516600090815260fe6020526040902054168361168c565b80356001600160a01b038116811461209657600080fd5b919050565b600080604083850312156120ae57600080fd5b6120b78361207f565b91506120c56020840161207f565b90509250929050565b6000815180845260005b818110156120f4576020818501810151868301820152016120d8565b506000602082860101526020601f19601f83011685010191505092915050565b6020815260006106a760208301846120ce565b6000806040838503121561213a57600080fd5b6121438361207f565b946020939093013593505050565b60008060006060848603121561216657600080fd5b61216f8461207f565b925061217d6020850161207f565b9150604084013590509250925092565b60006020828403121561219f57600080fd5b5035919050565b6000806000604084860312156121bb57600080fd5b833567ffffffffffffffff808211156121d357600080fd5b818601915086601f8301126121e757600080fd5b8135818111156121f657600080fd5b8760208260051b850101111561220b57600080fd5b602092830195509350612221918601905061207f565b90509250925092565b60006020828403121561223c57600080fd5b6106a78261207f565b60ff60f81b881681526000602060e08184015261226560e084018a6120ce565b8381036040850152612277818a6120ce565b606085018990526001600160a01b038816608086015260a0850187905284810360c0860152855180825283870192509083019060005b818110156122c9578351835292840192918401916001016122ad565b50909c9b505050505050505050505050565b803560ff8116811461209657600080fd5b60008060008060008060c0878903121561230557600080fd5b61230e8761207f565b9550602087013594506040870135935061232a606088016122db565b92506080870135915060a087013590509295509295509295565b600080600080600080600060e0888a03121561235f57600080fd5b6123688861207f565b96506123766020890161207f565b95506040880135945060608801359350612392608089016122db565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156123c157600080fd5b6123ca8361207f565b9150602083013563ffffffff811681146123e357600080fd5b809150509250929050565b600181811c9082168061240257607f821691505b6020821081036114fb57634e487b7160e01b600052602260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561059557610595612422565b634e487b7160e01b600052603260045260246000fd5b60006001820161247357612473612422565b5060010190565b634e487b7160e01b600052604160045260246000fd5b6000602082840312156124a257600080fd5b5051919050565b8181038181111561059557610595612422565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052601260045260246000fd5b60008261253a57634e487b7160e01b600052601260045260246000fd5b500490565b601f8211156117c557600081815260208120601f850160051c810160208610156125665750805b601f850160051c820191505b8181101561258557828155600101612572565b505050505050565b815167ffffffffffffffff8111156125a7576125a761247a565b6125bb816125b584546123ee565b8461253f565b602080601f8311600181146125f057600084156125d85750858301515b600019600386901b1c1916600185901b178555612585565b600085815260208120601f198616915b8281101561261f57888601518255948401946001909101908401612600565b508582101561263d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052602160045260246000fdfea164736f6c6343000811000a