Add mint to adapters - #340
Draft
naddison36 wants to merge 8 commits into
Draft
Conversation
naddison36
force-pushed
the
nicka/adapter-mint
branch
from
August 21, 2026 07:01
a8b624e to
6e73122
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds asynchronous minting to the generic asset-adapter interface, allowing ARM liquidity to be converted into base-asset inventory.
The Paxos adapters use this flow to mint PYUSD and USDG with USDC. Once Paxos settlement completes, the minted assets are claimed by the ARM and can be sold through the existing Uniswap V2-compatible swap interface.
Adapter lifecycle operations are extracted into the externally linked
ARMAdapterLib, bringingMultiAssetARMback under Ethereum's EIP-170 contract-size limit without changing optimizer runs or any swap functions.Changes
Generic adapter interface
requestMintandclaimMinttoIAssetAdapter.MintNotSupportedfor adapters that only support redemption.IAssetAdapterinterface; redemption-only adapters explicitly revert from mint operations.Adapter interface
ARM minting and accounting
pendingMintSharesthrough its public mapping getter.totalAssets()using the base asset's configured cross price.ARMAdapterLib.Paxos adapters
Deployment
ARMDeploymentHelperto deployARMAdapterLiband linkMultiAssetARMcreation bytecode to the deployed library.ARMAdapterLib;Paxos mint flow
Accounting
Pending mint inventory is valued using the base asset's cross price.
At a cross price of
1e36, requesting, settling, and claiming a mint is NAV-neutral. Below1e36, the configured discount is recognized when USDC is committed.Mint and redemption balances are isolated so:
Contract size
MultiAssetARM: 24,437 bytes, leaving 139 bytes below Ethereum's 24,576-byte EIP-170 limit.ARMAdapterLib: 2,478 bytes.The optimizer run count is unchanged.
Tests
Coverage includes:
MultiAssetARMunit and fuzz tests;MintNotSupportedbehavior;