From 4eaa128a06bb99805cb2e65254ad3799dacb889d Mon Sep 17 00:00:00 2001 From: Tom Meagher Date: Mon, 15 Dec 2025 15:36:16 -0500 Subject: [PATCH 1/4] feat: add max depth guard for named tuples --- package.json | 5 +- packages/abitype/src/generated.ts | 1263 +++++++++++++++++++++++++ packages/abitype/src/utils.bench-d.ts | 82 +- packages/abitype/src/utils.ts | 80 +- packages/abitype/test/globalSetup.ts | 7 +- pnpm-lock.yaml | 189 ++-- scripts/genAbiParameterNameLookup.ts | 2 +- 7 files changed, 1492 insertions(+), 136 deletions(-) diff --git a/package.json b/package.json index a4b62a19..787149f3 100644 --- a/package.json +++ b/package.json @@ -1,4 +1,5 @@ { + "name": "abitype", "private": true, "type": "module", "scripts": { @@ -30,7 +31,7 @@ "version:update": "node scripts/updateVersion.ts" }, "devDependencies": { - "@arktype/attest": "0.8.0", + "@ark/attest": "^0.56.0", "@biomejs/biome": "1.9.4", "@changesets/cli": "^3.0.0-next.0", "@ethersproject/abi": "^5.7.0", @@ -43,7 +44,7 @@ "publint": "^0.2.12", "sherif": "^0.9.0", "simple-git-hooks": "^2.11.1", - "typescript": "5.7.2", + "typescript": "5.9.3", "vitest": "^4.0.10" }, "packageManager": "pnpm@10.16.1", diff --git a/packages/abitype/src/generated.ts b/packages/abitype/src/generated.ts index e220333b..e86f748c 100644 --- a/packages/abitype/src/generated.ts +++ b/packages/abitype/src/generated.ts @@ -1,260 +1,1523 @@ export interface AbiParameterTupleNameLookup extends Record { + _a: [_a: type] + _acceptablePrice: [_acceptablePrice: type] _account: [_account: type] + _accounts: [_accounts: type] + _action: [_action: type] + _actionId: [_actionId: type] + _active: [_active: type] + _adapter: [_adapter: type] + _adapterParams: [_adapterParams: type] + _add: [_add: type] _addr: [_addr: type] _address: [_address: type] + _addresses: [_addresses: type] + _admin: [_admin: type] + _agent: [_agent: type] + _aggregator: [_aggregator: type] + _allocPoint: [_allocPoint: type] + _allow: [_allow: type] + _allowed: [_allowed: type] + _amm: [_amm: type] _amount: [_amount: type] + _amountIn: [_amountIn: type] + _amountOut: [_amountOut: type] + _amountOutMin: [_amountOutMin: type] + _amountSetToken: [_amountSetToken: type] _amounts: [_amounts: type] + _amt: [_amt: type] + _app: [_app: type] + _approved: [_approved: type] + _args: [_args: type] _asset: [_asset: type] + _assetAddr: [_assetAddr: type] + _assetId: [_assetId: type] + _assets: [_assets: type] + _attribute: [_attribute: type] + _auctionId: [_auctionId: type] + _avatar: [_avatar: type] + _b: [_b: type] + _balance: [_balance: type] + _balances: [_balances: type] + _base: [_base: type] + _baseToken: [_baseToken: type] + _baseURI: [_baseURI: type] + _batch: [_batch: type] + _batchId: [_batchId: type] + _beneficiary: [_beneficiary: type] + _bidId: [_bidId: type] + _block: [_block: type] + _blockNumber: [_blockNumber: type] + _bool: [_bool: type] + _borrowAmount: [_borrowAmount: type] _borrower: [_borrower: type] + _bps: [_bps: type] + _bridge: [_bridge: type] + _bridgeData: [_bridgeData: type] + _burnFee: [_burnFee: type] + _burn_amount: [_burn_amount: type] + _buyFee: [_buyFee: type] + _buyInAmount: [_buyInAmount: type] + _buyer: [_buyer: type] + _c: [_c: type] + _cType: [_cType: type] + _callData: [_callData: type] + _calldata: [_calldata: type] + _caller: [_caller: type] + _campaignId: [_campaignId: type] + _cap: [_cap: type] + _category: [_category: type] + _categoryId: [_categoryId: type] + _ccy: [_ccy: type] + _cdpId: [_cdpId: type] _chainId: [_chainId: type] + _cid: [_cid: type] + _claim: [_claim: type] + _claimId: [_claimId: type] + _claimer: [_claimer: type] + _clanId: [_clanId: type] + _code: [_code: type] _collateral: [_collateral: type] + _collateralAddress: [_collateralAddress: type] + _collateralAmount: [_collateralAmount: type] + _collateralAsset: [_collateralAsset: type] + _collateralDelta: [_collateralDelta: type] + _collateralIndex: [_collateralIndex: type] + _collateralToken: [_collateralToken: type] + _collateralType: [_collateralType: type] + _collaterals: [_collaterals: type] + _collection: [_collection: type] + _collectionId: [_collectionId: type] + _component: [_component: type] + _compound: [_compound: type] + _comptrollerProxy: [_comptrollerProxy: type] + _config: [_config: type] _contract: [_contract: type] + _contractAddress: [_contractAddress: type] + _contractName: [_contractName: type] + _contractURI: [_contractURI: type] + _contracts: [_contracts: type] + _contributor: [_contributor: type] + _controller: [_controller: type] + _cost: [_cost: type] + _count: [_count: type] + _creator: [_creator: type] + _currency: [_currency: type] + _dao: [_dao: type] _data: [_data: type] + _date: [_date: type] + _day: [_day: type] + _days: [_days: type] _deadline: [_deadline: type] + _debt: [_debt: type] + _decimals: [_decimals: type] + _defaultAdmin: [_defaultAdmin: type] + _delay: [_delay: type] + _delegate: [_delegate: type] + _delegatee: [_delegatee: type] + _delegator: [_delegator: type] + _delta: [_delta: type] + _denominator: [_denominator: type] + _deployer: [_deployer: type] + _deposit: [_deposit: type] + _depositAmount: [_depositAmount: type] + _depositId: [_depositId: type] + _depositToken: [_depositToken: type] + _depositor: [_depositor: type] + _description: [_description: type] + _destination: [_destination: type] + _dev: [_dev: type] + _devFee: [_devFee: type] + _dex: [_dex: type] + _discount: [_discount: type] + _disputeID: [_disputeID: type] + _distributor: [_distributor: type] + _domain: [_domain: type] + _dst: [_dst: type] + _dstChainId: [_dstChainId: type] + _dstEid: [_dstEid: type] + _dstPoolId: [_dstPoolId: type] _duration: [_duration: type] + _editionId: [_editionId: type] + _editionNumber: [_editionNumber: type] + _editionSize: [_editionSize: type] + _eid: [_eid: type] + _enable: [_enable: type] _enabled: [_enabled: type] + _end: [_end: type] + _endBlock: [_endBlock: type] + _endDate: [_endDate: type] + _endIndex: [_endIndex: type] + _endTime: [_endTime: type] + _endTimestamp: [_endTimestamp: type] + _entity: [_entity: type] + _entityAddress: [_entityAddress: type] + _epoch: [_epoch: type] + _epochId: [_epochId: type] + _erc20: [_erc20: type] + _eventId: [_eventId: type] + _evidence: [_evidence: type] + _exchange: [_exchange: type] + _executionFee: [_executionFee: type] + _executionFeeReceiver: [_executionFeeReceiver: type] + _executor: [_executor: type] + _expiration: [_expiration: type] + _expiry: [_expiry: type] + _extraData: [_extraData: type] + _factory: [_factory: type] _fee: [_fee: type] + _feePercent: [_feePercent: type] + _feeRate: [_feeRate: type] + _feeReceiver: [_feeReceiver: type] + _feeRecipient: [_feeRecipient: type] + _feeToken: [_feeToken: type] + _fees: [_fees: type] + _flag: [_flag: type] + _for: [_for: type] _from: [_from: type] + _fromToken: [_fromToken: type] + _futureId: [_futureId: type] + _game: [_game: type] + _gameId: [_gameId: type] + _gameIds: [_gameIds: type] + _gasLimit: [_gasLimit: type] + _gauge: [_gauge: type] + _gauges: [_gauges: type] + _generation: [_generation: type] + _governance: [_governance: type] + _group: [_group: type] + _groupId: [_groupId: type] + _guardian: [_guardian: type] + _handler: [_handler: type] + _hash: [_hash: type] + _hatId: [_hatId: type] + _holder: [_holder: type] + _hook: [_hook: type] + _hopData: [_hopData: type] + _iToken: [_iToken: type] _id: [_id: type] + _idempotencyKey: [_idempotencyKey: type] + _ids: [_ids: type] + _idx: [_idx: type] + _implementation: [_implementation: type] _index: [_index: type] + _indexToken: [_indexToken: type] + _indices: [_indices: type] + _info: [_info: type] + _initialOwner: [_initialOwner: type] + _input: [_input: type] + _inputToken: [_inputToken: type] + _inputs: [_inputs: type] + _integrator: [_integrator: type] + _interval: [_interval: type] + _isActive: [_isActive: type] + _isEnabled: [_isEnabled: type] + _isLong: [_isLong: type] + _isPaused: [_isPaused: type] + _issuer: [_issuer: type] + _itemId: [_itemId: type] + _itemIds: [_itemIds: type] + _keeper: [_keeper: type] + _key: [_key: type] + _keyHash: [_keyHash: type] + _l1Token: [_l1Token: type] + _label: [_label: type] + _legoId: [_legoId: type] + _lender: [_lender: type] + _lenderId: [_lenderId: type] + _length: [_length: type] + _level: [_level: type] + _leverage: [_leverage: type] + _limit: [_limit: type] + _linkId: [_linkId: type] + _liqUser: [_liqUser: type] + _liquidator: [_liquidator: type] + _liquidity: [_liquidity: type] + _liquidityFee: [_liquidityFee: type] + _listingId: [_listingId: type] + _loan: [_loan: type] + _loanId: [_loanId: type] + _location: [_location: type] + _lock: [_lock: type] + _lockDuration: [_lockDuration: type] + _lockId: [_lockId: type] + _long: [_long: type] + _lowerHint: [_lowerHint: type] + _lp: [_lp: type] + _lpAddress: [_lpAddress: type] + _lpAmount: [_lpAmount: type] + _lpToken: [_lpToken: type] + _manager: [_manager: type] + _marginDelta: [_marginDelta: type] _market: [_market: type] + _marketId: [_marketId: type] + _marketIndex: [_marketIndex: type] + _marketKey: [_marketKey: type] + _marketing: [_marketing: type] + _marketingFee: [_marketingFee: type] + _maturity: [_maturity: type] + _max: [_max: type] + _maxAmount: [_maxAmount: type] + _maxFeePercentage: [_maxFeePercentage: type] + _maxPrice: [_maxPrice: type] + _maxSupply: [_maxSupply: type] + _member: [_member: type] + _memo: [_memo: type] _merkleProof: [_merkleProof: type] + _merkleRoot: [_merkleRoot: type] + _message: [_message: type] + _messageId: [_messageId: type] + _metadata: [_metadata: type] + _min: [_min: type] + _minAmount: [_minAmount: type] + _minAmountOut: [_minAmountOut: type] + _minOut: [_minOut: type] + _minPrice: [_minPrice: type] + _minReturn: [_minReturn: type] + _mintAmount: [_mintAmount: type] + _mintPrice: [_mintPrice: type] + _minter: [_minter: type] + _mode: [_mode: type] + _module: [_module: type] + _multiplier: [_multiplier: type] + _n: [_n: type] _name: [_name: type] + _names: [_names: type] + _new: [_new: type] + _newAddress: [_newAddress: type] + _newAmount: [_newAmount: type] + _newFee: [_newFee: type] + _newImpl: [_newImpl: type] + _newLimit: [_newLimit: type] + _newOwner: [_newOwner: type] + _newPrice: [_newPrice: type] + _newStatus: [_newStatus: type] + _newValue: [_newValue: type] + _nft: [_nft: type] + _nftAddress: [_nftAddress: type] + _nftContract: [_nftContract: type] + _nftContractAddress: [_nftContractAddress: type] + _nftID: [_nftID: type] + _nftId: [_nftId: type] + _nftIndex: [_nftIndex: type] + _nftTokenId: [_nftTokenId: type] + _nfts: [_nfts: type] + _node: [_node: type] + _nodeAddress: [_nodeAddress: type] + _nodeId: [_nodeId: type] + _nodeType: [_nodeType: type] _nonce: [_nonce: type] + _num: [_num: type] + _number: [_number: type] + _of: [_of: type] + _offer: [_offer: type] + _offerId: [_offerId: type] + _offset: [_offset: type] + _open: [_open: type] + _operator: [_operator: type] + _option: [_option: type] + _optionId: [_optionId: type] + _options: [_options: type] + _oracle: [_oracle: type] + _order: [_order: type] + _orderId: [_orderId: type] + _orderIndex: [_orderIndex: type] + _orderType: [_orderType: type] + _origin: [_origin: type] + _outcome: [_outcome: type] + _outputToken: [_outputToken: type] _owner: [_owner: type] + _ownerAddress: [_ownerAddress: type] + _owners: [_owners: type] + _pair: [_pair: type] + _pairId: [_pairId: type] _pairIndex: [_pairIndex: type] + _pairs: [_pairs: type] + _param: [_param: type] + _parameters: [_parameters: type] _params: [_params: type] + _participant: [_participant: type] + _path: [_path: type] + _pause: [_pause: type] + _paused: [_paused: type] + _payToken: [_payToken: type] + _payload: [_payload: type] + _paymentAmount: [_paymentAmount: type] + _paymentToken: [_paymentToken: type] + _percent: [_percent: type] + _percentage: [_percentage: type] + _period: [_period: type] + _permitData: [_permitData: type] + _phase: [_phase: type] _pid: [_pid: type] + _pids: [_pids: type] + _platform: [_platform: type] + _player: [_player: type] + _playerId: [_playerId: type] + _plotID: [_plotID: type] + _point: [_point: type] _pool: [_pool: type] + _poolAddress: [_poolAddress: type] + _poolID: [_poolID: type] _poolId: [_poolId: type] + _poolManagerId: [_poolManagerId: type] + _poolToken: [_poolToken: type] + _poolTokenAddress: [_poolTokenAddress: type] + _pools: [_pools: type] + _posId: [_posId: type] + _position: [_position: type] + _positionId: [_positionId: type] + _positionManager: [_positionManager: type] _price: [_price: type] + _priceData: [_priceData: type] + _priceFeed: [_priceFeed: type] + _priceInWei: [_priceInWei: type] + _priceUpdateData: [_priceUpdateData: type] + _prices: [_prices: type] + _productId: [_productId: type] + _profileId: [_profileId: type] _projectId: [_projectId: type] _proof: [_proof: type] + _proofs: [_proofs: type] + _prop: [_prop: type] + _property: [_property: type] + _proposal: [_proposal: type] + _proposalID: [_proposalID: type] + _proposalId: [_proposalId: type] + _protocolFee: [_protocolFee: type] + _protocolId: [_protocolId: type] + _provider: [_provider: type] + _proxy: [_proxy: type] + _qty: [_qty: type] + _quantities: [_quantities: type] _quantity: [_quantity: type] + _questId: [_questId: type] + _quoteAsset: [_quoteAsset: type] + _r: [_r: type] + _raffleId: [_raffleId: type] + _rarity: [_rarity: type] + _rate: [_rate: type] + _ratio: [_ratio: type] + _realmId: [_realmId: type] + _reason: [_reason: type] _receiver: [_receiver: type] + _receivers: [_receivers: type] _recipient: [_recipient: type] + _recipients: [_recipients: type] + _refer: [_refer: type] + _referral: [_referral: type] + _referralCode: [_referralCode: type] + _referrer: [_referrer: type] + _refundAddress: [_refundAddress: type] + _registry: [_registry: type] + _reportId: [_reportId: type] + _request: [_request: type] + _requestId: [_requestId: type] + _reserve: [_reserve: type] + _reservePrice: [_reservePrice: type] + _reward: [_reward: type] + _rewardAmount: [_rewardAmount: type] + _rewardPerBlock: [_rewardPerBlock: type] + _rewardToken: [_rewardToken: type] + _rewardTokens: [_rewardTokens: type] + _rewarder: [_rewarder: type] + _rewards: [_rewards: type] + _rewardsToken: [_rewardsToken: type] + _role: [_role: type] + _root: [_root: type] + _round: [_round: type] + _roundID: [_roundID: type] + _roundId: [_roundId: type] + _route: [_route: type] + _router: [_router: type] + _s: [_s: type] + _safe: [_safe: type] + _saleId: [_saleId: type] + _salt: [_salt: type] + _season: [_season: type] + _seconds: [_seconds: type] + _selector: [_selector: type] + _sellFee: [_sellFee: type] + _seller: [_seller: type] _sender: [_sender: type] + _seriesId: [_seriesId: type] + _set: [_set: type] + _setAmount: [_setAmount: type] _setToken: [_setToken: type] + _settings: [_settings: type] + _share: [_share: type] + _shares: [_shares: type] + _sharesAmount: [_sharesAmount: type] + _side: [_side: type] + _sig: [_sig: type] _signature: [_signature: type] + _signatures: [_signatures: type] + _signer: [_signer: type] + _sigs: [_sigs: type] + _silo: [_silo: type] + _size: [_size: type] + _sizeDelta: [_sizeDelta: type] + _slippage: [_slippage: type] + _slot: [_slot: type] + _source: [_source: type] + _spender: [_spender: type] + _srcAddress: [_srcAddress: type] + _srcChainId: [_srcChainId: type] + _stake: [_stake: type] + _stakeID: [_stakeID: type] + _stakeToken: [_stakeToken: type] + _staker: [_staker: type] + _stakerAddress: [_stakerAddress: type] + _staking: [_staking: type] + _stakingModuleId: [_stakingModuleId: type] + _stakingToken: [_stakingToken: type] + _start: [_start: type] + _startBlock: [_startBlock: type] + _startDate: [_startDate: type] + _startIndex: [_startIndex: type] + _startTime: [_startTime: type] + _startTimestamp: [_startTimestamp: type] _state: [_state: type] _status: [_status: type] + _strategies: [_strategies: type] + _strategist: [_strategist: type] _strategy: [_strategy: type] + _subAccount: [_subAccount: type] + _subAccountId: [_subAccountId: type] + _subgraphDeploymentID: [_subgraphDeploymentID: type] + _subject: [_subject: type] + _subscriptionId: [_subscriptionId: type] + _supply: [_supply: type] + _swap: [_swap: type] + _swapData: [_swapData: type] + _swapRouter: [_swapRouter: type] _symbol: [_symbol: type] + _t: [_t: type] _target: [_target: type] + _targets: [_targets: type] + _taskId: [_taskId: type] + _team: [_team: type] + _teamId: [_teamId: type] + _threshold: [_threshold: type] + _tier: [_tier: type] + _tierId: [_tierId: type] + _tigAsset: [_tigAsset: type] + _time: [_time: type] _timestamp: [_timestamp: type] _to: [_to: type] + _toAddress: [_toAddress: type] + _toToken: [_toToken: type] _token: [_token: type] + _token0: [_token0: type] + _token1: [_token1: type] + _tokenA: [_tokenA: type] + _tokenAddr: [_tokenAddr: type] _tokenAddress: [_tokenAddress: type] + _tokenAddresses: [_tokenAddresses: type] + _tokenAmount: [_tokenAmount: type] + _tokenB: [_tokenB: type] + _tokenContract: [_tokenContract: type] + _tokenID: [_tokenID: type] _tokenId: [_tokenId: type] _tokenIds: [_tokenIds: type] + _tokenIn: [_tokenIn: type] + _tokenName: [_tokenName: type] + _tokenOut: [_tokenOut: type] + _tokenSymbol: [_tokenSymbol: type] + _tokenType: [_tokenType: type] + _tokenURI: [_tokenURI: type] _tokens: [_tokens: type] + _total: [_total: type] + _totalAmount: [_totalAmount: type] + _totalSupply: [_totalSupply: type] + _tournamentId: [_tournamentId: type] + _trade: [_trade: type] + _tradeData: [_tradeData: type] + _trader: [_trader: type] + _tranche: [_tranche: type] + _transactionId: [_transactionId: type] + _transferFee: [_transferFee: type] + _treasury: [_treasury: type] + _treasuryFee: [_treasuryFee: type] + _trigger: [_trigger: type] + _triggerAboveThreshold: [_triggerAboveThreshold: type] + _triggerPrice: [_triggerPrice: type] + _troveId: [_troveId: type] _type: [_type: type] + _underlying: [_underlying: type] + _underlyingAsset: [_underlyingAsset: type] + _universe: [_universe: type] + _unlockTime: [_unlockTime: type] + _updateData: [_updateData: type] + _upperHint: [_upperHint: type] + _uri: [_uri: type] _user: [_user: type] + _userAddr: [_userAddr: type] + _userAddress: [_userAddress: type] + _users: [_users: type] + _v: [_v: type] + _val: [_val: type] + _validator: [_validator: type] + _validatorId: [_validatorId: type] _value: [_value: type] + _values: [_values: type] _vault: [_vault: type] + _vaultId: [_vaultId: type] + _vaultProxy: [_vaultProxy: type] + _vaultToken: [_vaultToken: type] + _vaults: [_vaults: type] + _verifier: [_verifier: type] + _version: [_version: type] + _vestingId: [_vestingId: type] + _voter: [_voter: type] _wallet: [_wallet: type] + _walletAddress: [_walletAddress: type] + _week: [_week: type] + _weiAmount: [_weiAmount: type] + _weight: [_weight: type] + _weights: [_weights: type] + _weth: [_weth: type] + _whitelist: [_whitelist: type] + _who: [_who: type] + _withUpdate: [_withUpdate: type] + _withdrawAmount: [_withdrawAmount: type] + _worker: [_worker: type] + _x: [_x: type] + _y: [_y: type] + _zroPaymentAddress: [_zroPaymentAddress: type] a: [a: type] + acceptableFixedInterestRate: [acceptableFixedInterestRate: type] account: [account: type] + accountAddress: [accountAddress: type] + accountId: [accountId: type] + account_: [account_: type] accounts: [accounts: type] + action: [action: type] + actions: [actions: type] + active: [active: type] + adapter: [adapter: type] + add: [add: type] addr: [addr: type] + addr_: [addr_: type] address: [address: type] + address_: [address_: type] addresses: [addresses: type] + addrs: [addrs: type] + addy: [addy: type] admin: [admin: type] + adr: [adr: type] + affiliate: [affiliate: type] + agent: [agent: type] + allocation: [allocation: type] + allow: [allow: type] allowFailure: [allowFailure: type] + allowance: [allowance: type] allowed: [allowed: type] + amm: [amm: type] amount: [amount: type] + amount0: [amount0: type] + amount0Min: [amount0Min: type] + amount1: [amount1: type] + amount1Min: [amount1Min: type] + amountADesired: [amountADesired: type] + amountAMin: [amountAMin: type] + amountBDesired: [amountBDesired: type] + amountBMin: [amountBMin: type] + amountETHMin: [amountETHMin: type] amountIn: [amountIn: type] + amountInMax: [amountInMax: type] amountOut: [amountOut: type] amountOutMin: [amountOutMin: type] + amountOutMinimum: [amountOutMinimum: type] + amountTokenDesired: [amountTokenDesired: type] + amountTokenMin: [amountTokenMin: type] amount_: [amount_: type] amounts: [amounts: type] + amounts_: [amounts_: type] + amt: [amt: type] + ancillaryData: [ancillaryData: type] + app: [app: type] + appId: [appId: type] + approveMax: [approveMax: type] approved: [approved: type] approver: [approver: type] arg0: [arg0: type] + arg1: [arg1: type] + args: [args: type] ask: [ask: type] asset: [asset: type] + assetAddress: [assetAddress: type] + assetAmount: [assetAmount: type] + assetId: [assetId: type] + assetIds: [assetIds: type] + assetToken: [assetToken: type] + assetType: [assetType: type] + asset_: [asset_: type] assets: [assets: type] + auctionId: [auctionId: type] + author: [author: type] authority: [authority: type] + authorized: [authorized: type] available: [available: type] b: [b: type] balance: [balance: type] + balances: [balances: type] + base: [base: type] + baseAmount: [baseAmount: type] + baseToken: [baseToken: type] + baseURI: [baseURI: type] + baseURI_: [baseURI_: type] + baseUri: [baseUri: type] + batch: [batch: type] + batchId: [batchId: type] + batchSize: [batchSize: type] beneficiary: [beneficiary: type] bid: [bid: type] + bidder: [bidder: type] + binStep: [binStep: type] + blockNumber: [blockNumber: type] + boardId: [boardId: type] + bond: [bond: type] + borrowAmount: [borrowAmount: type] borrower: [borrower: type] + borrowers: [borrowers: type] + boxId: [boxId: type] + bps: [bps: type] + bridgeRequest: [bridgeRequest: type] buffer: [buffer: type] + bundleId: [bundleId: type] + burn: [burn: type] + burnAmount: [burnAmount: type] + burner: [burner: type] + buy: [buy: type] + buyAmount: [buyAmount: type] + buyToken: [buyToken: type] + buyer: [buyer: type] c: [c: type] + cToken: [cToken: type] + cTokens: [cTokens: type] call: [call: type] callData: [callData: type] + callback: [callback: type] + callbackData: [callbackData: type] + calldatas: [calldatas: type] caller: [caller: type] + caller_: [caller_: type] calls: [calls: type] + campaign: [campaign: type] + campaignId: [campaignId: type] + candidate: [candidate: type] + cap: [cap: type] + category: [category: type] + categoryId: [categoryId: type] + cdp: [cdp: type] chainId: [chainId: type] + chainId_: [chainId_: type] + channel: [channel: type] + channelId: [channelId: type] + cityId: [cityId: type] + claim: [claim: type] + claimAmount: [claimAmount: type] + claimId: [claimId: type] + claimer: [claimer: type] + claims: [claims: type] clone: [clone: type] + code: [code: type] + coin: [coin: type] + coinIndex: [coinIndex: type] coinType: [coinType: type] collateral: [collateral: type] + collateralAmount: [collateralAmount: type] + collateralAsset: [collateralAsset: type] + collateralId: [collateralId: type] + collateralToken: [collateralToken: type] + collateralType: [collateralType: type] collection: [collection: type] + collectionAddress: [collectionAddress: type] + collectionId: [collectionId: type] + collection_: [collection_: type] + cometProxy: [cometProxy: type] + comment: [comment: type] + component: [component: type] + comptroller: [comptroller: type] + comptroller_: [comptroller_: type] + conditionId: [conditionId: type] + config: [config: type] + context: [context: type] + contractAddr: [contractAddr: type] contractAddress: [contractAddress: type] + contributor: [contributor: type] + controller: [controller: type] + core: [core: type] + cost: [cost: type] count: [count: type] + coverId: [coverId: type] + creator: [creator: type] + creatorContractAddress: [creatorContractAddress: type] + creditAccount: [creditAccount: type] + creditor: [creditor: type] + ctx: [ctx: type] + cup: [cup: type] + curr: [curr: type] currency: [currency: type] + currencyAmount: [currencyAmount: type] + currencyCt: [currencyCt: type] + currencyId: [currencyId: type] + currencyKey: [currencyKey: type] + currencyKeys: [currencyKeys: type] + currency_: [currency_: type] + cursor: [cursor: type] d: [d: type] data: [data: type] + dataStore: [dataStore: type] + data_: [data_: type] + datas: [datas: type] + date: [date: type] + day: [day: type] + deadLine: [deadLine: type] deadline: [deadline: type] + deadline_: [deadline_: type] + debt: [debt: type] decimals: [decimals: type] + decimals_: [decimals_: type] + defaultAdmin: [defaultAdmin: type] + delegate: [delegate: type] + delegatee: [delegatee: type] + delegator: [delegator: type] + delta: [delta: type] + denominator: [denominator: type] + deployer: [deployer: type] + deposit: [deposit: type] + depositAmount: [depositAmount: type] + depositData: [depositData: type] + depositId: [depositId: type] + depositToken: [depositToken: type] + depositor: [depositor: type] + desc: [desc: type] + description: [description: type] dest: [dest: type] + destToken: [destToken: type] + destination: [destination: type] + destinationAddress: [destinationAddress: type] + destinationChain: [destinationChain: type] + destinationChainId: [destinationChainId: type] + destinationDomain: [destinationDomain: type] + details: [details: type] + dev: [dev: type] + dexData: [dexData: type] + dexId: [dexId: type] + direction: [direction: type] + disabled: [disabled: type] + distributionId: [distributionId: type] + distributor: [distributor: type] divisor: [divisor: type] dns: [dns: type] + domain: [domain: type] + domainHash: [domainHash: type] + domainSeparator: [domainSeparator: type] + dropId: [dropId: type] + dsId: [dsId: type] dst: [dst: type] + dstChainId: [dstChainId: type] + dungeonId: [dungeonId: type] duration: [duration: type] + dx: [dx: type] e: [e: type] + edition: [edition: type] + editionId: [editionId: type] + eid: [eid: type] + enable: [enable: type] enabled: [enabled: type] + end: [end: type] + endIdx: [endIdx: type] + endIndex: [endIndex: type] endTime: [endTime: type] + endTime_: [endTime_: type] + endTimestamp: [endTimestamp: type] ens: [ens: type] epoch: [epoch: type] + epochId: [epochId: type] + erc20: [erc20: type] + erc20Address: [erc20Address: type] + erc721Address: [erc721Address: type] errorData: [errorData: type] + eth: [eth: type] + ethAmount: [ethAmount: type] + eventId: [eventId: type] + exchange: [exchange: type] + exchangeData: [exchangeData: type] + exchangeId: [exchangeId: type] + excluded: [excluded: type] + executor: [executor: type] + exempt: [exempt: type] + expiration: [expiration: type] + expirationTime: [expirationTime: type] expiry: [expiry: type] + extension: [extension: type] + extraData: [extraData: type] f: [f: type] + factory: [factory: type] failures: [failures: type] + farmId: [farmId: type] fee: [fee: type] + feeAmount: [feeAmount: type] + feeBps: [feeBps: type] + feeRecipient: [feeRecipient: type] + feeType: [feeType: type] + fee_: [fee_: type] + fees: [fees: type] + fid: [fid: type] + flag: [flag: type] + flags: [flags: type] from: [from: type] + fromAmount: [fromAmount: type] + fromMode: [fromMode: type] + fromToken: [fromToken: type] + from_: [from_: type] + fund: [fund: type] funder: [funder: type] + fyToken: [fyToken: type] g: [g: type] + gameId: [gameId: type] + gas: [gas: type] + gasLimit: [gasLimit: type] gateway: [gateway: type] gateways: [gateways: type] + gauge: [gauge: type] + goodUntil: [goodUntil: type] + group: [group: type] + groupId: [groupId: type] + guardian: [guardian: type] + guildId: [guildId: type] guy: [guy: type] h: [h: type] + handler: [handler: type] hash: [hash: type] hashes: [hashes: type] + hero: [hero: type] + heroId: [heroId: type] + heroToken: [heroToken: type] holder: [holder: type] + holders: [holders: type] + hook: [hook: type] + hookData: [hookData: type] + host: [host: type] i: [i: type] id: [id: type] + id_: [id_: type] + identifier: [identifier: type] + identity: [identity: type] ids: [ids: type] idsLength: [idsLength: type] + idx: [idx: type] + ilk: [ilk: type] + ilkIndex: [ilkIndex: type] + impl: [impl: type] implementation: [implementation: type] + inbound_tkn: [inbound_tkn: type] + increase: [increase: type] index: [index: type] + indexToken: [indexToken: type] + index_: [index_: type] + indexes: [indexes: type] + indices: [indices: type] + info: [info: type] + initData: [initData: type] + initialExchangeRateMantissa_: [initialExchangeRateMantissa_: type] + initialOwner: [initialOwner: type] + initiator: [initiator: type] + input: [input: type] + inputAmount: [inputAmount: type] + inputAsset: [inputAsset: type] + inputToken: [inputToken: type] + inputs: [inputs: type] + instanceId: [instanceId: type] + instrument: [instrument: type] + instrumentId: [instrumentId: type] + interestRateModel_: [interestRateModel_: type] interfaceId: [interfaceId: type] + interval: [interval: type] + investor: [investor: type] + ipfsHash: [ipfsHash: type] + isActive: [isActive: type] + isAllowed: [isAllowed: type] + isEnabled: [isEnabled: type] + isExcluded: [isExcluded: type] + isLong: [isLong: type] + isPaused: [isPaused: type] + issuer: [issuer: type] + item: [item: type] + itemId: [itemId: type] + itemIds: [itemIds: type] + items: [items: type] j: [j: type] k: [k: type] + keeper: [keeper: type] key: [key: type] + keys: [keys: type] + kind: [kind: type] l: [l: type] label: [label: type] + leaf: [leaf: type] + lender: [lender: type] length: [length: type] + level: [level: type] + leverage: [leverage: type] + lien: [lien: type] + lienId: [lienId: type] limit: [limit: type] + liquidator: [liquidator: type] liquidity: [liquidity: type] + liquidityFee: [liquidityFee: type] + listingId: [listingId: type] + loan: [loan: type] + loanId: [loanId: type] + lock: [lock: type] + lockDuration: [lockDuration: type] + lockTime: [lockTime: type] + locked: [locked: type] + long: [long: type] + lp: [lp: type] + lpAmount: [lpAmount: type] + lpToken: [lpToken: type] + lpTokens: [lpTokens: type] m: [m: type] + maker: [maker: type] + makerSignature: [makerSignature: type] + manager: [manager: type] + margin: [margin: type] + marginAccountID: [marginAccountID: type] market: [market: type] marketId: [marketId: type] + marketId_: [marketId_: type] + marketIndex: [marketIndex: type] + marketParams: [marketParams: type] + marketing: [marketing: type] + marketingFee: [marketingFee: type] + markets: [markets: type] + maturity: [maturity: type] + max: [max: type] + maxAmount: [maxAmount: type] + maxAmountIn: [maxAmountIn: type] + maxPrice: [maxPrice: type] + maxSupply: [maxSupply: type] + member: [member: type] memo: [memo: type] + merchant: [merchant: type] merkleProof: [merkleProof: type] + merkleProofs: [merkleProofs: type] + merkleRoot: [merkleRoot: type] + merkleRoot_: [merkleRoot_: type] message: [message: type] + messageHash: [messageHash: type] + metadata: [metadata: type] + metadataURI: [metadataURI: type] + min: [min: type] + minAmount: [minAmount: type] + minAmountOut: [minAmountOut: type] + minAmounts: [minAmounts: type] + minBuyAmount: [minBuyAmount: type] + minOut: [minOut: type] + minPrice: [minPrice: type] + minReturn: [minReturn: type] + minReturnAmount: [minReturnAmount: type] + miner: [miner: type] + mintAmount: [mintAmount: type] + mintId: [mintId: type] + minter: [minter: type] + minter_: [minter_: type] + mode: [mode: type] + module: [module: type] + month: [month: type] + msgSender: [msgSender: type] + multiplier: [multiplier: type] n: [n: type] name: [name: type] name_: [name_: type] + names: [names: type] + namespace: [namespace: type] + ne: [ne: type] needed: [needed: type] new: [new: type] newAddress: [newAddress: type] + newAdmin: [newAdmin: type] + newAmount: [newAmount: type] + newContract: [newContract: type] + newFee: [newFee: type] + newImplementation: [newImplementation: type] + newLimit: [newLimit: type] + newManager: [newManager: type] + newMax: [newMax: type] + newName: [newName: type] + newOwner: [newOwner: type] + newPrice: [newPrice: type] + newRate: [newRate: type] + newRatio: [newRatio: type] + newRecipient: [newRecipient: type] + newStatus: [newStatus: type] + newThreshold: [newThreshold: type] newValue: [newValue: type] + newWallet: [newWallet: type] next: [next: type] nextOwner: [nextOwner: type] + nft: [nft: type] + nftAddress: [nftAddress: type] + nftAsset: [nftAsset: type] + nftContract: [nftContract: type] + nftID: [nftID: type] + nftId: [nftId: type] + nftIds: [nftIds: type] + nftRecipient: [nftRecipient: type] + nftTokenId: [nftTokenId: type] + nft_: [nft_: type] node: [node: type] + nodeID: [nodeID: type] + nodeId: [nodeId: type] + nodeIndex: [nodeIndex: type] + nodeOperatorId: [nodeOperatorId: type] nonce: [nonce: type] nonceKey: [nonceKey: type] + nonce_: [nonce_: type] + num: [num: type] + numToMint: [numToMint: type] + numTokens: [numTokens: type] + number: [number: type] + numberOfTokens: [numberOfTokens: type] numerator: [numerator: type] o: [o: type] + offer: [offer: type] + offerId: [offerId: type] offerer: [offerer: type] + offset: [offset: type] + olKey: [olKey: type] old: [old: type] + onBehalf: [onBehalf: type] + onBehalfOf: [onBehalfOf: type] + open: [open: type] + operation: [operation: type] operator: [operator: type] + operatorId: [operatorId: type] + operatorIds: [operatorIds: type] + operators: [operators: type] + option: [option: type] + options: [options: type] + oracle: [oracle: type] + oracles: [oracles: type] order: [order: type] + orderHash: [orderHash: type] orderId: [orderId: type] + orderType: [orderType: type] + order_: [order_: type] orders: [orders: type] + outbound_tkn: [outbound_tkn: type] + output: [output: type] + outputAmount: [outputAmount: type] + outputReference: [outputReference: type] + outputToken: [outputToken: type] owner: [owner: type] + ownerAddress: [ownerAddress: type] + owner_: [owner_: type] + owners: [owners: type] p: [p: type] + pToken: [pToken: type] + pageSize: [pageSize: type] + pair: [pair: type] + pairId: [pairId: type] + pairIndex: [pairIndex: type] + pairs: [pairs: type] + param: [param: type] + parameters: [parameters: type] params: [params: type] + params_: [params_: type] + parentId: [parentId: type] + partner: [partner: type] + partyA: [partyA: type] path: [path: type] + paths: [paths: type] + pause: [pause: type] + paused: [paused: type] + payee: [payee: type] + payer: [payer: type] + payload: [payload: type] + paymentToken: [paymentToken: type] + percent: [percent: type] + percentage: [percentage: type] + period: [period: type] + permission: [permission: type] + permissions: [permissions: type] + permit: [permit: type] + permitData: [permitData: type] + permitDeadline: [permitDeadline: type] + petId: [petId: type] + phase: [phase: type] + pid: [pid: type] + plan: [plan: type] + planId: [planId: type] + player: [player: type] + playerId: [playerId: type] + points: [points: type] policyId: [policyId: type] policyType: [policyType: type] pool: [pool: type] + poolAddress: [poolAddress: type] + poolFee: [poolFee: type] + poolHash: [poolHash: type] + poolID: [poolID: type] poolId: [poolId: type] + poolId_: [poolId_: type] + poolIndex: [poolIndex: type] + poolKey: [poolKey: type] + poolToken: [poolToken: type] + poolType: [poolType: type] + pool_: [pool_: type] + pools: [pools: type] + pos: [pos: type] + position: [position: type] + positionId: [positionId: type] + positions: [positions: type] previous: [previous: type] previousOwner: [previousOwner: type] price: [price: type] + priceUpdateData: [priceUpdateData: type] + price_: [price_: type] + prices: [prices: type] primary: [primary: type] + principal: [principal: type] + product: [product: type] productId: [productId: type] + profileId: [profileId: type] + profit: [profit: type] + projectId: [projectId: type] proof: [proof: type] + proof_: [proof_: type] + proofs: [proofs: type] + proposal: [proposal: type] proposalId: [proposalId: type] proposer: [proposer: type] + protocol: [protocol: type] + provider: [provider: type] + proxy: [proxy: type] + publicKey: [publicKey: type] q: [q: type] + qty: [qty: type] + quantities: [quantities: type] quantity: [quantity: type] queries: [queries: type] + questID: [questID: type] + questId: [questId: type] + questId_: [questId_: type] + questionID: [questionID: type] + question_id: [question_id: type] + quorumNumber: [quorumNumber: type] + quote: [quote: type] + quoteId: [quoteId: type] quoteToken: [quoteToken: type] r: [r: type] + raffleId: [raffleId: type] + rarity: [rarity: type] + rate: [rate: type] + ratio: [ratio: type] + reason: [reason: type] receiver: [receiver: type] + receiverAddress: [receiverAddress: type] + receiver_: [receiver_: type] + receivers: [receivers: type] recipient: [recipient: type] + recipient_: [recipient_: type] recipients: [recipients: type] + redeemer: [redeemer: type] + ref: [ref: type] + referral: [referral: type] + referralCode: [referralCode: type] + referralId: [referralId: type] referrer: [referrer: type] refund: [refund: type] + refundAddress: [refundAddress: type] + registry: [registry: type] + relayer: [relayer: type] + repayAmount: [repayAmount: type] + req: [req: type] + request: [request: type] + requestId: [requestId: type] + requestIds: [requestIds: type] + requester: [requester: type] + requests: [requests: type] required: [required: type] + rescueOrder: [rescueOrder: type] + reserve: [reserve: type] + reserveId: [reserveId: type] resolvedName: [resolvedName: type] resolver: [resolver: type] + resourceID: [resourceID: type] responses: [responses: type] restricted: [restricted: type] + result: [result: type] returnData: [returnData: type] reverseName: [reverseName: type] reverseResolver: [reverseResolver: type] + reward: [reward: type] + rewardAmount: [rewardAmount: type] + rewardToken: [rewardToken: type] + rewards: [rewards: type] + riskIndicatorsInputs: [riskIndicatorsInputs: type] role: [role: type] + roleId: [roleId: type] + roles: [roles: type] + root: [root: type] + round: [round: type] + roundId: [roundId: type] + route: [route: type] + router: [router: type] + routes: [routes: type] s: [s: type] + safe: [safe: type] salt: [salt: type] + scId: [scId: type] + schainHash: [schainHash: type] + schainName: [schainName: type] + score: [score: type] + season: [season: type] + seasonId: [seasonId: type] + secret: [secret: type] secs: [secs: type] + seed: [seed: type] selector: [selector: type] + sell: [sell: type] + sellAmount: [sellAmount: type] + sellOrder: [sellOrder: type] + sellToken: [sellToken: type] + seller: [seller: type] sender: [sender: type] + seriesId: [seriesId: type] + serviceId: [serviceId: type] + settings: [settings: type] + share: [share: type] + shareAmount: [shareAmount: type] shares: [shares: type] + sharesAmount: [sharesAmount: type] + sharesSubject: [sharesSubject: type] + shares_: [shares_: type] + side: [side: type] sig: [sig: type] signature: [signature: type] + signature_: [signature_: type] signatures: [signatures: type] signer: [signer: type] + size: [size: type] + sizeDelta: [sizeDelta: type] + slippage: [slippage: type] + slot: [slot: type] + slot_: [slot_: type] + smartVault: [smartVault: type] source: [source: type] + sourceAmount: [sourceAmount: type] + sourceToken: [sourceToken: type] spender: [spender: type] + sqrtPriceLimitX96: [sqrtPriceLimitX96: type] + sqrtPriceX96: [sqrtPriceX96: type] src: [src: type] + srcAmount: [srcAmount: type] + srcToken: [srcToken: type] + stable: [stable: type] + stage: [stage: type] + stake: [stake: type] + stakeAmount: [stakeAmount: type] + stakeId: [stakeId: type] + stakeIndex: [stakeIndex: type] staker: [staker: type] + stakerAddr: [stakerAddr: type] + stakingToken: [stakingToken: type] + starkKey: [starkKey: type] start: [start: type] + startDate: [startDate: type] + startIdx: [startIdx: type] + startIndex: [startIndex: type] startTime: [startTime: type] + startTime_: [startTime_: type] + startTimestamp: [startTimestamp: type] state: [state: type] status: [status: type] + statuses: [statuses: type] + strategies: [strategies: type] + strategy: [strategy: type] + streamId: [streamId: type] + strike: [strike: type] + subAccountId: [subAccountId: type] + subId: [subId: type] + subaccount: [subaccount: type] + subject: [subject: type] + subjectType: [subjectType: type] + subscriber: [subscriber: type] success: [success: type] + superToken: [superToken: type] + supply: [supply: type] + support: [support: type] + swap: [swap: type] + swapData: [swapData: type] + swapFee: [swapFee: type] + swapFeePercentage: [swapFeePercentage: type] + swapId: [swapId: type] + swapParams: [swapParams: type] + swapTarget: [swapTarget: type] + swaps: [swaps: type] + sweepTokens: [sweepTokens: type] symbol: [symbol: type] symbol_: [symbol_: type] t: [t: type] + tAmount: [tAmount: type] + tableId: [tableId: type] + tag: [tag: type] + taker: [taker: type] target: [target: type] + targetAddress: [targetAddress: type] + targetContract: [targetContract: type] + targetToken: [targetToken: type] + targets: [targets: type] + taskId: [taskId: type] + tax: [tax: type] + taxFee: [taxFee: type] + term: [term: type] + termAuctionId: [termAuctionId: type] + termId: [termId: type] + termRepoId: [termRepoId: type] + theSignature: [theSignature: type] + threshold: [threshold: type] + tick: [tick: type] + tickLower: [tickLower: type] + tickSpacing: [tickSpacing: type] + tickUpper: [tickUpper: type] + ticketId: [ticketId: type] + tid: [tid: type] + tier: [tier: type] + tierId: [tierId: type] + time: [time: type] timestamp: [timestamp: type] to: [to: type] + toAddress: [toAddress: type] + toChain: [toChain: type] + toChainId: [toChainId: type] + toToken: [toToken: type] + to_: [to_: type] + tok: [tok: type] token: [token: type] + token0: [token0: type] + token1: [token1: type] + tokenA: [tokenA: type] + tokenAddr: [tokenAddr: type] tokenAddress: [tokenAddress: type] + tokenAddresses: [tokenAddresses: type] tokenAmount: [tokenAmount: type] + tokenAmountIn: [tokenAmountIn: type] + tokenAmounts: [tokenAmounts: type] + tokenB: [tokenB: type] + tokenContract: [tokenContract: type] + tokenID: [tokenID: type] + tokenIDs: [tokenIDs: type] tokenId: [tokenId: type] tokenId_: [tokenId_: type] tokenIds: [tokenIds: type] + tokenIds_: [tokenIds_: type] tokenIn: [tokenIn: type] + tokenIndex: [tokenIndex: type] + tokenName: [tokenName: type] tokenOut: [tokenOut: type] + tokenOwner: [tokenOwner: type] + tokenRecipient: [tokenRecipient: type] + tokenSymbol: [tokenSymbol: type] + tokenType: [tokenType: type] + tokenURI: [tokenURI: type] + tokenUri: [tokenUri: type] + tokenX: [tokenX: type] + tokenY: [tokenY: type] + token_: [token_: type] + tokenid: [tokenid: type] tokens: [tokens: type] + tokens_: [tokens_: type] + tos: [tos: type] + total: [total: type] + totalAmount: [totalAmount: type] + totalSupply: [totalSupply: type] + tournamentId: [tournamentId: type] + trade: [trade: type] trader: [trader: type] + traitId: [traitId: type] + tranche: [tranche: type] + trancheId: [trancheId: type] + transactionId: [transactionId: type] + treasury: [treasury: type] + true_or_false: [true_or_false: type] + ts: [ts: type] ttl: [ttl: type] + txHash: [txHash: type] + typeId: [typeId: type] + type_: [type_: type] u: [u: type] + underlying: [underlying: type] + underlyingToken: [underlyingToken: type] + underlying_: [underlying_: type] + updateData: [updateData: type] updater: [updater: type] + uri: [uri: type] + uri_: [uri_: type] + url: [url: type] + usdcAmount: [usdcAmount: type] user: [user: type] + userAddr: [userAddr: type] userAddress: [userAddress: type] + userData: [userData: type] + userId: [userId: type] + userOp: [userOp: type] + user_: [user_: type] users: [users: type] + usr: [usr: type] v: [v: type] + vToken: [vToken: type] + val: [val: type] + validAfter: [validAfter: type] + validBefore: [validBefore: type] + validUntil: [validUntil: type] + validator: [validator: type] + validatorId: [validatorId: type] value: [value: type] + value_: [value_: type] values: [values: type] valuesLength: [valuesLength: type] + vars: [vars: type] vault: [vault: type] + vaultAddress: [vaultAddress: type] + vaultAddresses: [vaultAddresses: type] + vaultID: [vaultID: type] vaultId: [vaultId: type] + vault_: [vault_: type] + vectorId: [vectorId: type] + verifier: [verifier: type] version: [version: type] + volume: [volume: type] + voter: [voter: type] + vs: [vs: type] w: [w: type] wad: [wad: type] wallet: [wallet: type] + walletAddress: [walletAddress: type] + wallet_: [wallet_: type] + wallets: [wallets: type] + week: [week: type] + weight: [weight: type] + weights: [weights: type] weth: [weth: type] + what: [what: type] + whitelist: [whitelist: type] + whitelisted: [whitelisted: type] + who: [who: type] + withdrawAmount: [withdrawAmount: type] + worldId: [worldId: type] + wrappedToken: [wrappedToken: type] x: [x: type] y: [y: type] + year: [year: type] + yieldToken: [yieldToken: type] z: [z: type] + zeroForOne: [zeroForOne: type] zone: [zone: type] } diff --git a/packages/abitype/src/utils.bench-d.ts b/packages/abitype/src/utils.bench-d.ts index 23fde430..2b23c788 100644 --- a/packages/abitype/src/utils.bench-d.ts +++ b/packages/abitype/src/utils.bench-d.ts @@ -1,4 +1,4 @@ -import { attest } from '@arktype/attest' +import { attest } from '@ark/attest' import { describe, test } from 'vitest' import type { erc20Abi } from './abis/json.js' import type { @@ -54,9 +54,19 @@ describe('AbiParameterToPrimitiveType', () => { nonce: bigint fee: number }>({} as Result) - attest({} as Result).type.toString.snap( - '{ name: string; symbol: string; description: string; imageURI: string; contentURI: string; price: bigint; limit: bigint; fundingRecipient: `0x${string}`; renderer: `0x${string}`; nonce: bigint; fee: number; }', - ) + attest({} as Result).type.toString.snap(`{ + name: string + symbol: string + description: string + imageURI: string + contentURI: string + price: bigint + limit: bigint + fundingRecipient: \`0x\${string}\` + renderer: \`0x\${string}\` + nonce: bigint + fee: number +}`) }) test('array', () => { @@ -273,18 +283,28 @@ type transferFrom = ExtractAbiFunction< 'transferFrom' >['inputs'] test('basic without named tuple', () => { - const res = {} as AbiParametersToPrimitiveTypes + type Result = AbiParametersToPrimitiveTypes + const res = {} as Result attest.instantiations([906, 'instantiations']) attest< readonly [sender: `0x${string}`, recipient: `0x${string}`, amount: bigint] >(res) + attest(res).type.toString.snap( + 'readonly [`0x${string}`, `0x${string}`, bigint]', + ) }) test('basic with named tuple', () => { - const res = {} as AbiParametersToPrimitiveTypes + type Result = AbiParametersToPrimitiveTypes + const res = {} as Result attest.instantiations([1131, 'instantiations']) attest< readonly [sender: `0x${string}`, recipient: `0x${string}`, amount: bigint] >(res) + attest(res).type.toString.snap(`readonly [ + sender: \`0x\${string}\`, + recipient: \`0x\${string}\`, + amount: bigint +]`) }) type parameters = readonly [ @@ -310,10 +330,56 @@ type parameters = readonly [ { name: 'policyType'; type: 'uint8' }, ] test('without named tuples', () => { - ;({}) as AbiParametersToPrimitiveTypes + type Result = AbiParametersToPrimitiveTypes + ;({}) as Result attest.instantiations([1276, 'instantiations']) + attest({} as Result).type.toString.snap(`readonly [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + \`0x\${string}\`, + number, + number, + number, + number, + number, + number, + number +]`) }) test('with named tuples', () => { - ;({}) as AbiParametersToPrimitiveTypes + type Result = AbiParametersToPrimitiveTypes + ;({}) as Result attest.instantiations([1998, 'instantiations']) + attest({} as Result).type.toString.snap(`readonly [ + account: number, + address: number, + admin: number, + allowed: number, + amount: number, + authority: number, + available: number, + count: number, + currency: number, + deadline: number, + from: number, + funder: number, + hash: \`0x\${string}\`, + id: number, + memo: number, + nonce: number, + nonceKey: number, + owner: number, + policyId: number, + policyType: number +]`) }) diff --git a/packages/abitype/src/utils.ts b/packages/abitype/src/utils.ts index b46ff978..0b707a2f 100644 --- a/packages/abitype/src/utils.ts +++ b/packages/abitype/src/utils.ts @@ -211,53 +211,43 @@ export type AbiParametersToPrimitiveTypes_named< abiParameterKind extends AbiParameterKind = AbiParameterKind, /// acc extends readonly unknown[] = [], + depth extends readonly number[] = [], // FIXME: Workaround to create labeled tuple so parameter names show up in autocomplete // e.g. [foo: string, bar: string] // Ideally this is a simple mapped type instead of tail recurision, but TypeScript does not support dynamic tuple labels // https://github.com/microsoft/TypeScript/issues/44939 -> = abiParameters extends readonly [ - // Significantly reduce type instantiations by batch proccessing up to six parameters at a time instead of processing one parameter per recursion - infer head1 extends AbiParameter, - infer head2 extends AbiParameter, - infer head3 extends AbiParameter, - infer head4 extends AbiParameter, - infer head5 extends AbiParameter, - infer head6 extends AbiParameter, - ...infer tail extends readonly AbiParameter[], -] - ? AbiParametersToPrimitiveTypes_named< - tail, - abiParameterKind, - readonly [ - ...acc, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ] - > +> = depth['length'] extends 15 + ? readonly unknown[] : abiParameters extends readonly [ + // Significantly reduce type instantiations by batch proccessing up to six parameters at a time instead of processing one parameter per recursion infer head1 extends AbiParameter, infer head2 extends AbiParameter, infer head3 extends AbiParameter, infer head4 extends AbiParameter, infer head5 extends AbiParameter, + infer head6 extends AbiParameter, + ...infer tail extends readonly AbiParameter[], ] - ? readonly [ - ...acc, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ...ToNamedTuple, - ] + ? AbiParametersToPrimitiveTypes_named< + tail, + abiParameterKind, + readonly [ + ...acc, + ...ToNamedTuple, + ...ToNamedTuple, + ...ToNamedTuple, + ...ToNamedTuple, + ...ToNamedTuple, + ...ToNamedTuple, + ], + [...depth, 1] + > : abiParameters extends readonly [ infer head1 extends AbiParameter, infer head2 extends AbiParameter, infer head3 extends AbiParameter, infer head4 extends AbiParameter, + infer head5 extends AbiParameter, ] ? readonly [ ...acc, @@ -265,34 +255,48 @@ export type AbiParametersToPrimitiveTypes_named< ...ToNamedTuple, ...ToNamedTuple, ...ToNamedTuple, + ...ToNamedTuple, ] : abiParameters extends readonly [ infer head1 extends AbiParameter, infer head2 extends AbiParameter, infer head3 extends AbiParameter, + infer head4 extends AbiParameter, ] ? readonly [ ...acc, ...ToNamedTuple, ...ToNamedTuple, ...ToNamedTuple, + ...ToNamedTuple, ] : abiParameters extends readonly [ infer head1 extends AbiParameter, infer head2 extends AbiParameter, + infer head3 extends AbiParameter, ] ? readonly [ ...acc, ...ToNamedTuple, ...ToNamedTuple, + ...ToNamedTuple, ] - : abiParameters extends readonly [infer head extends AbiParameter] - ? readonly [...acc, ...ToNamedTuple] - : acc extends readonly [] - ? abiParameters extends readonly [] - ? readonly [] - : readonly unknown[] - : acc + : abiParameters extends readonly [ + infer head1 extends AbiParameter, + infer head2 extends AbiParameter, + ] + ? readonly [ + ...acc, + ...ToNamedTuple, + ...ToNamedTuple, + ] + : abiParameters extends readonly [infer head extends AbiParameter] + ? readonly [...acc, ...ToNamedTuple] + : acc extends readonly [] + ? abiParameters extends readonly [] + ? readonly [] + : readonly unknown[] + : acc type ToNamedTuple< abiParameter extends AbiParameter, diff --git a/packages/abitype/test/globalSetup.ts b/packages/abitype/test/globalSetup.ts index 6b435666..0a11976b 100644 --- a/packages/abitype/test/globalSetup.ts +++ b/packages/abitype/test/globalSetup.ts @@ -1,6 +1,6 @@ import { dirname, resolve } from 'node:path' import { fileURLToPath } from 'node:url' -import { setup } from '@arktype/attest' +import { setup } from '@ark/attest' const __filename = fileURLToPath(import.meta.url) const __dirname = dirname(__filename) @@ -8,10 +8,7 @@ const __dirname = dirname(__filename) export default function () { return setup({ benchErrorOnThresholdExceeded: true, + formatCmd: 'pnpm biome format --write', tsconfig: resolve(__dirname, '../tsconfig.json'), - formatter: 'pnpm biome format --write', }) } - -// biome-ignore lint/performance/noBarrelFile: -export { teardown } from '@arktype/attest' diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 5fba44ff..fc2ce87e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -8,9 +8,9 @@ importers: .: devDependencies: - '@arktype/attest': - specifier: 0.8.0 - version: 0.8.0(typescript@5.7.2) + '@ark/attest': + specifier: ^0.56.0 + version: 0.56.0(typescript@5.9.3) '@biomejs/biome': specifier: 1.9.4 version: 1.9.4 @@ -37,10 +37,10 @@ importers: version: 10.4.2 knip: specifier: ^5.22.3 - version: 5.22.3(@types/node@24.10.1)(typescript@5.7.2) + version: 5.22.3(@types/node@24.10.1)(typescript@5.9.3) node: specifier: runtime:^24.5.1 - version: runtime:24.11.1 + version: runtime:24.12.0 publint: specifier: ^0.2.12 version: 0.2.12 @@ -51,8 +51,8 @@ importers: specifier: ^2.11.1 version: 2.11.1 typescript: - specifier: 5.7.2 - version: 5.7.2 + specifier: 5.9.3 + version: 5.9.3 vitest: specifier: ^4.0.10 version: 4.0.10(@types/debug@4.1.12)(@types/node@24.10.1)(jiti@1.21.0)(yaml@2.4.2) @@ -82,7 +82,7 @@ importers: version: 18.3.1(react@18.3.1) vocs: specifier: 1.0.0-alpha.17 - version: 1.0.0-alpha.17(@types/node@24.10.1)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.53.2)(typescript@5.7.2) + version: 1.0.0-alpha.17(@types/node@24.10.1)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.53.2)(typescript@5.9.3) packages/abitype: dependencies: @@ -125,23 +125,20 @@ packages: resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} engines: {node: '>=6.0.0'} - '@ark/schema@0.55.0': - resolution: {integrity: sha512-IlSIc0FmLKTDGr4I/FzNHauMn0MADA6bCjT1wauu4k6MyxhC1R9gz0olNpIRvK7lGGDwtc/VO0RUDNvVQW5WFg==} - - '@ark/util@0.55.0': - resolution: {integrity: sha512-aWFNK7aqSvqFtVsl1xmbTjGbg91uqtJV7Za76YGNEwIO4qLjMfyY8flmmbhooYMuqPCO2jyxu8hve943D+w3bA==} - - '@arktype/attest@0.8.0': - resolution: {integrity: sha512-wxQ8PdXSrlQyHzlQeXiMMARumAS4whpuvvqV+DWWDECAhrsyhV0yixAavapz1X7qu8253cCiF6h/dabpGYAtpw==} + '@ark/attest@0.56.0': + resolution: {integrity: sha512-Pngs8f1UJiWbeO8LKVdyBL0K3rT/PDVACR7TPyCEULNcN8V1rVec6dKvUnQVpQSj60p4ejlK6dKs+fQoqdUMqA==} hasBin: true peerDependencies: typescript: '*' - '@arktype/fs@0.0.20': - resolution: {integrity: sha512-WnoIFrhiDKnWixd7xmcvFTlP7ZVReT7j37nTbCpieUCsVaUldb38pgQjxdvlJN40UL3kkjxyiYIRmc7BOvgy1A==} + '@ark/fs@0.56.0': + resolution: {integrity: sha512-zY/wDDhcvmt6/upQwZM766PAnvIzdEMcgydUGd9pqY9FMGNo9I9uE4RYAfms9AeUUtbZJu2h2Ua0tvFsO5XF4Q==} + + '@ark/schema@0.56.0': + resolution: {integrity: sha512-ECg3hox/6Z/nLajxXqNhgPtNdHWC9zNsDyskwO28WinoFEnWow4IsERNz9AnXRhTZJnYIlAJ4uGn3nlLk65vZA==} - '@arktype/util@0.0.49': - resolution: {integrity: sha512-ptlPUDZ8EECx23S7OjQnMulUSt8lmhxq5pQXmiyMlVt9g9EhUOVpdFrNqSCntFURtennxwFDJaYa+7rKQrGrew==} + '@ark/util@0.56.0': + resolution: {integrity: sha512-BghfRC8b9pNs3vBoDJhcta0/c1J1rsoS1+HgVUreMFPdhz/CRAKReAu57YEllNaSy98rWAdY1gE+gFup7OXpgA==} '@babel/code-frame@7.24.2': resolution: {integrity: sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==} @@ -1020,6 +1017,11 @@ packages: '@popperjs/core@2.11.8': resolution: {integrity: sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==} + '@prettier/sync@0.6.1': + resolution: {integrity: sha512-yF9G8vK/LYUTF3Cijd7VC9La3b20F20/J/fgoR4H0B8JGOWnZVZX6+I6+vODPosjmMcpdlUV+gUqJQZp3kLOcw==} + peerDependencies: + prettier: '*' + '@radix-ui/colors@3.0.0': resolution: {integrity: sha512-FUOsGBkHrYJwCSEtWRCIfQbZG7q1e6DgxCIOe1SUQzDe/7rXXeA47s8yCn6fuTNQAj1Zq4oTFi9Yjp3wzElcxg==} @@ -1692,8 +1694,8 @@ packages: '@typescript/vfs@1.5.0': resolution: {integrity: sha512-AJS307bPgbsZZ9ggCT3wwpg3VbTKMFNHfaY/uF0ahSkYYrPF2dSSKDNIDIQAHm9qJqbLvCsSJH7yN4Vs/CsMMg==} - '@typescript/vfs@1.5.3': - resolution: {integrity: sha512-OSZ/o3wwD5VPZVdGGsXWk7sRGRtwrGnqA4zwmb33FTs7Wxmad0QTkQCbaNyqWA8hL09TCwAthdp8yjFA5G1lvw==} + '@typescript/vfs@1.6.1': + resolution: {integrity: sha512-JwoxboBh7Oz1v38tPbkrZ62ZXNHAk9bJ7c9x0eI5zBfBnBYGhURdbnh7Z4smN/MV48Y5OCcZb58n972UtbazsA==} peerDependencies: typescript: '*' @@ -1832,11 +1834,11 @@ packages: arity-n@1.0.4: resolution: {integrity: sha512-fExL2kFDC1Q2DUOx3whE/9KoN66IzkY4b4zUHUBFM1ojEYjZZYDcUW3bek/ufGionX9giIKDC5redH2IlGqcQQ==} - arkregex@0.0.3: - resolution: {integrity: sha512-bU21QJOJEFJK+BPNgv+5bVXkvRxyAvgnon75D92newgHxkBJTgiFwQxusyViYyJkETsddPlHyspshDQcCzmkNg==} + arkregex@0.0.4: + resolution: {integrity: sha512-biS/FkvSwQq59TZ453piUp8bxMui11pgOMV9WHAnli1F8o0ayNCZzUwQadL/bGIUic5TkS/QlPcyMuI8ZIwedQ==} - arktype@2.1.27: - resolution: {integrity: sha512-enctOHxI4SULBv/TDtCVi5M8oLd4J5SVlPUblXDzSsOYQNMzmVbUosGBnJuZDKmFlN5Ie0/QVEuTE+Z5X1UhsQ==} + arktype@2.1.28: + resolution: {integrity: sha512-LVZqXl2zWRpNFnbITrtFmqeqNkPPo+KemuzbGSY6jvJwCb4v8NsDzrWOLHnQgWl26TkJeWWcUNUeBpq2Mst1/Q==} array-last@1.3.0: resolution: {integrity: sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg==} @@ -2738,6 +2740,9 @@ packages: resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==} engines: {node: '>=10'} + make-synchronized@0.8.0: + resolution: {integrity: sha512-DZu4lwc0ffoFz581BSQa/BJl+1ZqIkoRQ+VejMlH0VrP4E86StAODnZujZ4sepumQj8rcP7wUnUBGM8Gu+zKUA==} + map-obj@2.0.0: resolution: {integrity: sha512-TzQSV2DiMYgoF5RycneKVUzIa9bQsj/B3tTgsE3dOGqlzHnGIDaC7XBE7grnA+8kZPnfqSGFe95VHc2oc0VFUQ==} engines: {node: '>=4'} @@ -3024,95 +3029,94 @@ packages: node-releases@2.0.14: resolution: {integrity: sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==} - node@runtime:24.11.1: + node@runtime:24.12.0: resolution: type: variations variants: - resolution: archive: tarball bin: bin/node - integrity: sha256-mLqRmgOQ2MQi1LsxBexbd3I89UFDtMHkudd2kPoHUgY= + integrity: sha256-MfPQZbuE8GnlIuVdDTA1vTZMul2KIiM/9oAF0oHou3g= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-aix-ppc64.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-aix-ppc64.tar.gz targets: - cpu: ppc64 os: aix - resolution: archive: tarball bin: bin/node - integrity: sha256-sFqjpm7+aAAj+TC9WvP9u9VCeU2lZEyirXEdaMvU3DU= + integrity: sha256-MZ8iGtxeRP8O1X6KRBsihPArjcb8h7jrkqapNkP9gIA= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-darwin-arm64.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-darwin-arm64.tar.gz targets: - cpu: arm64 os: darwin - resolution: archive: tarball bin: bin/node - integrity: sha256-CWCBttb83T9boPXx1EpH6DA3rS546tomZxwlL+ZN0RE= + integrity: sha256-uC6kxi/QjiUMq1nWJeddd8xbCj1gxmmOvuRUXIihacU= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-darwin-x64.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-darwin-x64.tar.gz targets: - cpu: x64 os: darwin - resolution: archive: tarball bin: bin/node - integrity: sha256-Dck+xceYsNNH8GjbbSBdA96ppxdl5qU5IraCuRJl1x8= + integrity: sha256-myou65io6zc2EiTiodBgMArS3RQ69Y39sW3nhd8PEig= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-linux-arm64.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-linux-arm64.tar.gz targets: - cpu: arm64 os: linux - resolution: archive: tarball bin: bin/node - integrity: sha256-zUFAfzNS3i8GbqJsXF0OqbY2I3TWthg4Wp8una0iBhY= + integrity: sha256-Zux5tNZPQQmu34IhCHFdC2CXEY35FZwvYyFHfaTqF6o= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-linux-ppc64le.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-linux-ppc64le.tar.gz targets: - cpu: ppc64le os: linux - resolution: archive: tarball bin: bin/node - integrity: sha256-XUyLyl+PJZP5CB3uOYNHYOhaFvphyVDz6G7IWZbwBVA= + integrity: sha256-jclgolVdsap3/RMcJb5XG594RLyLJ454cyufWA/n1YA= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-linux-s390x.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-linux-s390x.tar.gz targets: - cpu: s390x os: linux - resolution: archive: tarball bin: bin/node - integrity: sha256-WKX/XMjyIA5Fi+oi4ynVwZlKobER1JnKRuwkEdWCOco= + integrity: sha256-YVkifgr318PGuy+pAEUrBKbLiEGnAqeazGEyCdcLBNA= type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-linux-x64.tar.gz + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-linux-x64.tar.gz targets: - cpu: x64 os: linux - resolution: archive: zip bin: node.exe - integrity: sha256-zp7k5Ufr3/NVvrSOMJsWbCTfa+ApHJ6vEDzhXz3p5bQ= - prefix: node-v24.11.1-win-arm64 + integrity: sha256-sF5+Bm+BPTWtPNnCTu2u4HTAEqx+AAcSl2CP3S6UiuM= + prefix: node-v24.12.0-win-arm64 type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-win-arm64.zip + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-win-arm64.zip targets: - cpu: arm64 os: win32 - resolution: archive: zip bin: node.exe - integrity: sha256-U1WubXxJ7dz959NKw0hoIGAKgxv4HcO9ylyNtqm7DnY= - prefix: node-v24.11.1-win-x64 + integrity: sha256-nBJfYa6Ue1LneQlYMPnKwmeEagQ+9xkhg8hAFqqtKBI= + prefix: node-v24.12.0-win-x64 type: binary - url: https://nodejs.org/download/release/v24.11.1/node-v24.11.1-win-x64.zip + url: https://nodejs.org/download/release/v24.12.0/node-v24.12.0-win-x64.zip targets: - cpu: x64 os: win32 - version: 24.11.1 - hasBin: true + version: 0.0.0 normalize-path@3.0.0: resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} @@ -3348,6 +3352,11 @@ packages: engines: {node: '>=10.13.0'} hasBin: true + prettier@3.6.2: + resolution: {integrity: sha512-I7AIg5boAr5R0FFtJ6rCfD+LFsWHp81dolrFD8S79U9tb8Az2nGrJncnMSnys+bpQJfRUzqs9hnA81OAA3hCuQ==} + engines: {node: '>=14'} + hasBin: true + pretty-ms@9.0.0: resolution: {integrity: sha512-E9e9HJ9R9NasGOgPaPE8VMeiPKAyWR5jcFpNnwIejslIhWqdqOrb2wShBsncMPUb+BcCd2OPYfh7p2W6oemTng==} engines: {node: '>=18'} @@ -3865,6 +3874,11 @@ packages: engines: {node: '>=14.17'} hasBin: true + typescript@5.9.3: + resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==} + engines: {node: '>=14.17'} + hasBin: true + ua-parser-js@1.0.37: resolution: {integrity: sha512-bhTyI94tZofjo+Dn8SN6Zv8nBDvyXTymAdM3LDI/0IboIUwTu1rEhW7v2TfiVsoYWgkQ4kOVqnI8APUFbIQIFQ==} @@ -4176,26 +4190,26 @@ snapshots: '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 - '@ark/schema@0.55.0': - dependencies: - '@ark/util': 0.55.0 - - '@ark/util@0.55.0': {} - - '@arktype/attest@0.8.0(typescript@5.7.2)': + '@ark/attest@0.56.0(typescript@5.9.3)': dependencies: - '@arktype/fs': 0.0.20 - '@arktype/util': 0.0.49 + '@ark/fs': 0.56.0 + '@ark/util': 0.56.0 + '@prettier/sync': 0.6.1(prettier@3.6.2) '@typescript/analyze-trace': 0.10.1 - '@typescript/vfs': 1.5.3(typescript@5.7.2) - arktype: 2.1.27 - typescript: 5.7.2 + '@typescript/vfs': 1.6.1(typescript@5.9.3) + arktype: 2.1.28 + prettier: 3.6.2 + typescript: 5.9.3 transitivePeerDependencies: - supports-color - '@arktype/fs@0.0.20': {} + '@ark/fs@0.56.0': {} - '@arktype/util@0.0.49': {} + '@ark/schema@0.56.0': + dependencies: + '@ark/util': 0.56.0 + + '@ark/util@0.56.0': {} '@babel/code-frame@7.24.2': dependencies: @@ -5050,6 +5064,11 @@ snapshots: '@popperjs/core@2.11.8': {} + '@prettier/sync@0.6.1(prettier@3.6.2)': + dependencies: + make-synchronized: 0.8.0 + prettier: 3.6.2 + '@radix-ui/colors@3.0.0': {} '@radix-ui/primitive@1.0.1': @@ -5653,13 +5672,13 @@ snapshots: treeify: 1.1.0 yargs: 16.2.0 - '@typescript/twoslash@3.2.4(typescript@5.7.2)': + '@typescript/twoslash@3.2.4(typescript@5.9.3)': dependencies: '@types/lz-string': 1.5.0 '@typescript/vfs': 1.5.0 debug: 4.3.4 lz-string: 1.5.0 - typescript: 5.7.2 + typescript: 5.9.3 transitivePeerDependencies: - supports-color @@ -5669,10 +5688,10 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript/vfs@1.5.3(typescript@5.7.2)': + '@typescript/vfs@1.6.1(typescript@5.9.3)': dependencies: - debug: 4.3.4 - typescript: 5.7.2 + debug: 4.4.3 + typescript: 5.9.3 transitivePeerDependencies: - supports-color @@ -5873,15 +5892,15 @@ snapshots: arity-n@1.0.4: {} - arkregex@0.0.3: + arkregex@0.0.4: dependencies: - '@ark/util': 0.55.0 + '@ark/util': 0.56.0 - arktype@2.1.27: + arktype@2.1.28: dependencies: - '@ark/schema': 0.55.0 - '@ark/util': 0.55.0 - arkregex: 0.0.3 + '@ark/schema': 0.56.0 + '@ark/util': 0.56.0 + arkregex: 0.0.4 array-last@1.3.0: dependencies: @@ -6790,7 +6809,7 @@ snapshots: jsonparse: 1.3.1 through2: 4.0.2 - knip@5.22.3(@types/node@24.10.1)(typescript@5.7.2): + knip@5.22.3(@types/node@24.10.1)(typescript@5.9.3): dependencies: '@ericcornelissen/bash-parser': 0.5.3 '@nodelib/fs.walk': 2.0.0 @@ -6809,7 +6828,7 @@ snapshots: strip-json-comments: 5.0.1 summary: 2.1.0 tsconfig-paths: 4.2.0 - typescript: 5.7.2 + typescript: 5.9.3 zod: 3.23.8 zod-validation-error: 3.3.0(zod@3.23.8) @@ -6868,6 +6887,8 @@ snapshots: dependencies: semver: 7.6.2 + make-synchronized@0.8.0: {} + map-obj@2.0.0: {} mark.js@8.11.1: {} @@ -7425,7 +7446,7 @@ snapshots: node-releases@2.0.14: {} - node@runtime:24.11.1: {} + node@runtime:24.12.0: {} normalize-path@3.0.0: {} @@ -7633,6 +7654,8 @@ snapshots: prettier@2.8.8: {} + prettier@3.6.2: {} + pretty-ms@9.0.0: dependencies: parse-ms: 4.0.0 @@ -8021,9 +8044,9 @@ snapshots: dependencies: shikiji: 0.9.19 - shikiji-twoslash@0.9.19(typescript@5.7.2): + shikiji-twoslash@0.9.19(typescript@5.9.3): dependencies: - '@typescript/twoslash': 3.2.4(typescript@5.7.2) + '@typescript/twoslash': 3.2.4(typescript@5.9.3) shikiji-core: 0.9.19 transitivePeerDependencies: - supports-color @@ -8247,6 +8270,8 @@ snapshots: typescript@5.7.2: {} + typescript@5.9.3: {} + ua-parser-js@1.0.37: {} ufo@1.5.3: {} @@ -8451,7 +8476,7 @@ snapshots: vlq@0.2.3: {} - vocs@1.0.0-alpha.17(@types/node@24.10.1)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.53.2)(typescript@5.7.2): + vocs@1.0.0-alpha.17(@types/node@24.10.1)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.53.2)(typescript@5.9.3): dependencies: '@hono/node-server': 1.11.1 '@mdx-js/react': 3.0.1(@types/react@18.3.3)(react@18.3.1) @@ -8466,7 +8491,7 @@ snapshots: '@radix-ui/react-navigation-menu': 1.1.4(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@radix-ui/react-popover': 1.0.7(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@radix-ui/react-tabs': 1.0.4(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) - '@typescript/twoslash': 3.2.4(typescript@5.7.2) + '@typescript/twoslash': 3.2.4(typescript@5.9.3) '@vanilla-extract/css': 1.15.2 '@vanilla-extract/dynamic': 2.1.1 '@vitejs/plugin-react': 4.2.0(vite@5.2.11(@types/node@24.10.1)) @@ -8507,7 +8532,7 @@ snapshots: serve-static: 1.15.0 shikiji: 0.9.19 shikiji-transformers: 0.9.19 - shikiji-twoslash: 0.9.19(typescript@5.7.2) + shikiji-twoslash: 0.9.19(typescript@5.9.3) tailwindcss: 3.4.3 toml: 3.0.0 ua-parser-js: 1.0.37 diff --git a/scripts/genAbiParameterNameLookup.ts b/scripts/genAbiParameterNameLookup.ts index 7e085b3c..499b8e6e 100644 --- a/scripts/genAbiParameterNameLookup.ts +++ b/scripts/genAbiParameterNameLookup.ts @@ -34,7 +34,7 @@ async function names() { .split('\n') .filter((line) => line.trim()) .map((line) => line.split(',')) - .filter(([, count]) => count && Number.parseInt(count) > 200) + .filter(([, count]) => count && Number.parseInt(count) > 24) .map((line) => line.at(0)) const customNames = [ '_data', From 445c53c5ed11e9450fcf49a04a1d448882474159 Mon Sep 17 00:00:00 2001 From: Tom Meagher Date: Mon, 15 Dec 2025 15:37:34 -0500 Subject: [PATCH 2/4] chore: changeset --- .changeset/afraid-facts-type.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/afraid-facts-type.md diff --git a/.changeset/afraid-facts-type.md b/.changeset/afraid-facts-type.md new file mode 100644 index 00000000..dba117bc --- /dev/null +++ b/.changeset/afraid-facts-type.md @@ -0,0 +1,5 @@ +--- +"abitype": patch +--- + +Added max depth guard for named tuple tail recursion From f33f60bbee5291f125121c62e2c8eda4b3641620 Mon Sep 17 00:00:00 2001 From: Tom Meagher Date: Mon, 15 Dec 2025 15:45:02 -0500 Subject: [PATCH 3/4] chore: pin actions --- .github/workflows/autofix.yml | 6 +++--- .github/workflows/changesets.yml | 10 +++++----- .github/workflows/issue-labeled.yml | 2 +- .github/workflows/lock-issue.yml | 2 +- .github/workflows/pull-request.yml | 14 +++++++------- .github/workflows/verify.yml | 18 +++++++++--------- package.json | 1 + packages/abitype/src/utils.bench-d.ts | 2 +- 8 files changed, 28 insertions(+), 27 deletions(-) diff --git a/.github/workflows/autofix.yml b/.github/workflows/autofix.yml index 0898ba1a..36e0cf99 100644 --- a/.github/workflows/autofix.yml +++ b/.github/workflows/autofix.yml @@ -18,10 +18,10 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Check code run: pnpm check @@ -30,6 +30,6 @@ jobs: run: pnpm version:update - name: Apply fixes - uses: autofix-ci/action@ff86a557419858bb967097bfc916833f5647fa8c + uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27 # v1.3.2 with: commit-message: 'ci: apply automated fixes' diff --git a/.github/workflows/changesets.yml b/.github/workflows/changesets.yml index caf8387a..f9ff217e 100644 --- a/.github/workflows/changesets.yml +++ b/.github/workflows/changesets.yml @@ -27,18 +27,18 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@ff7abcd0c3c05ccf6adc123a8cd1fd4fb30fb493 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 with: # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits fetch-depth: 0 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec with: node-version: 24.5 - name: PR or publish - uses: changesets/action@06245a4e0a36c064a573d4150030f5ec548e4fcc + uses: changesets/action@e0145edc7d9d8679003495b11f87bd8ef63c0cba # v1.5.3 with: title: 'chore: version packages' commit: 'chore: version packages' @@ -68,10 +68,10 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@ff7abcd0c3c05ccf6adc123a8cd1fd4fb30fb493 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Prepare run: pnpm node scripts/genJsrJson.ts && pnpm version:update && cd packages/abitype && cp ../../LICENSE LICENSE diff --git a/.github/workflows/issue-labeled.yml b/.github/workflows/issue-labeled.yml index c59200d2..9f183f01 100644 --- a/.github/workflows/issue-labeled.yml +++ b/.github/workflows/issue-labeled.yml @@ -7,7 +7,7 @@ on: jobs: issue-labeled: if: ${{ github.repository_owner == 'wevm' }} - uses: wevm/actions/.github/workflows/issue-labeled.yml@main + uses: wevm/actions/.github/workflows/issue-labeled.yml@f7ad7f00e16e73322562922c241f21f0c7ffbbec with: needs-reproduction-body: | Hello @${{ github.event.issue.user.login }}. diff --git a/.github/workflows/lock-issue.yml b/.github/workflows/lock-issue.yml index 3bb2bd95..963e4b64 100644 --- a/.github/workflows/lock-issue.yml +++ b/.github/workflows/lock-issue.yml @@ -7,7 +7,7 @@ on: jobs: lock-issue: if: ${{ github.repository_owner == 'wevm' }} - uses: wevm/actions/.github/workflows/lock-issue.yml@main + uses: wevm/actions/.github/workflows/lock-issue.yml@f7ad7f00e16e73322562922c241f21f0c7ffbbec with: issue-comment: | This issue has been locked since it has been closed for more than 14 days. diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 8777f989..2fd0ffca 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -20,12 +20,12 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 with: fetch-depth: 0 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Publish preview run: | @@ -41,10 +41,10 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Run benchmarks run: pnpm bench @@ -56,13 +56,13 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Report build size - uses: preactjs/compressed-size-action@v2 + uses: preactjs/compressed-size-action@946a292cd35bd1088e0d7eb92b69d1a8d5b5d76a # 2.8.0 with: pattern: 'packages/**/dist/**' repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index 812dc269..110c67b2 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -13,10 +13,10 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Check repo run: pnpm check:repo @@ -29,10 +29,10 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Build run: pnpm build @@ -54,10 +54,10 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Use `typescript@${{ matrix.version }}` run: pnpm add -D -w typescript@${{ matrix.version }} @@ -81,16 +81,16 @@ jobs: steps: - name: Clone repository - uses: actions/checkout@v5 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 - name: Install dependencies - uses: wevm/actions/.github/actions/pnpm@main + uses: wevm/actions/.github/actions/pnpm@f7ad7f00e16e73322562922c241f21f0c7ffbbec - name: Run tests run: pnpm test:cov - name: Upload coverage reports to Codecov - uses: codecov/codecov-action@v5 + uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2 with: token: ${{ secrets.CODECOV_TOKEN }} diff --git a/package.json b/package.json index 787149f3..88ccbc99 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,7 @@ "check:unused": "pnpm clean && knip", "clean": "pnpm run --r --parallel clean && rm -rf packages/**/*.json.tmp", "deps": "pnpx taze -r", + "deps:ci": "pnpx actions-up", "docs:dev": "pnpm -r --filter docs dev", "format": "biome format --write", "postinstall": "pnpm preconstruct", diff --git a/packages/abitype/src/utils.bench-d.ts b/packages/abitype/src/utils.bench-d.ts index 2b23c788..9e8b140e 100644 --- a/packages/abitype/src/utils.bench-d.ts +++ b/packages/abitype/src/utils.bench-d.ts @@ -285,7 +285,7 @@ type transferFrom = ExtractAbiFunction< test('basic without named tuple', () => { type Result = AbiParametersToPrimitiveTypes const res = {} as Result - attest.instantiations([906, 'instantiations']) + attest.instantiations([907, 'instantiations']) attest< readonly [sender: `0x${string}`, recipient: `0x${string}`, amount: bigint] >(res) From 26df7c25b87885e44e8770b06d544c6d2e80bca4 Mon Sep 17 00:00:00 2001 From: Tom Meagher Date: Mon, 15 Dec 2025 15:49:15 -0500 Subject: [PATCH 4/4] chore: bump --- packages/abitype/src/utils.bench-d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/abitype/src/utils.bench-d.ts b/packages/abitype/src/utils.bench-d.ts index 9e8b140e..9364d060 100644 --- a/packages/abitype/src/utils.bench-d.ts +++ b/packages/abitype/src/utils.bench-d.ts @@ -285,7 +285,7 @@ type transferFrom = ExtractAbiFunction< test('basic without named tuple', () => { type Result = AbiParametersToPrimitiveTypes const res = {} as Result - attest.instantiations([907, 'instantiations']) + attest.instantiations([910, 'instantiations']) attest< readonly [sender: `0x${string}`, recipient: `0x${string}`, amount: bigint] >(res)