From 2769fed744c4ec5a2cf6581addfc1704abfcba7c Mon Sep 17 00:00:00 2001 From: Siddharth Suresh Date: Wed, 24 Jun 2026 18:59:00 -0700 Subject: [PATCH] Add CAP-0084 muxed contract address XDR Adds the SC_ADDRESS_TYPE_MUXED_CONTRACT arm to SCAddress with a new MuxedContract { uint64 id; ContractID contractId; } struct, mirroring MuxedEd25519Account. Gated behind #ifdef CAP_0084 so it lands in `next` only until core bumps the max supported protocol. CAP-0084: https://github.com/stellar/stellar-protocol/pull/1968 --- Stellar-contract.x | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/Stellar-contract.x b/Stellar-contract.x index 0e67dc3..a5e844a 100644 --- a/Stellar-contract.x +++ b/Stellar-contract.x @@ -183,6 +183,10 @@ enum SCAddressType SC_ADDRESS_TYPE_MUXED_ACCOUNT = 2, SC_ADDRESS_TYPE_CLAIMABLE_BALANCE = 3, SC_ADDRESS_TYPE_LIQUIDITY_POOL = 4 +#ifdef CAP_0084 + , + SC_ADDRESS_TYPE_MUXED_CONTRACT = 5 +#endif }; struct MuxedEd25519Account @@ -191,6 +195,14 @@ struct MuxedEd25519Account uint256 ed25519; }; +#ifdef CAP_0084 +struct MuxedContract +{ + uint64 id; + ContractID contractId; +}; +#endif + union SCAddress switch (SCAddressType type) { case SC_ADDRESS_TYPE_ACCOUNT: @@ -203,6 +215,10 @@ case SC_ADDRESS_TYPE_CLAIMABLE_BALANCE: ClaimableBalanceID claimableBalanceId; case SC_ADDRESS_TYPE_LIQUIDITY_POOL: PoolID liquidityPoolId; +#ifdef CAP_0084 +case SC_ADDRESS_TYPE_MUXED_CONTRACT: + MuxedContract muxedContract; +#endif }; %struct SCVal;