4343 PsbtKeyTypeInputTapAnchorTapscriptSibling = []byte {0x78 }
4444 PsbtKeyTypeInputTapAsset = []byte {0x79 }
4545 PsbtKeyTypeInputTapAssetProof = []byte {0x7a }
46- PsbtKeyTypeInputAltLeaves = []byte {0x7b }
4746
4847 PsbtKeyTypeOutputTapType = []byte {0x70 }
4948 PsbtKeyTypeOutputTapIsInteractive = []byte {0x71 }
@@ -394,12 +393,6 @@ type VInput struct {
394393 // Proof is a transition proof that proves the asset being spent was
395394 // committed to in the anchor transaction above.
396395 Proof * proof.Proof
397-
398- // AltLeaves represent data used to construct an Asset commitment, that
399- // will be inserted in the input anchor Tap commitment. These
400- // data-carrying leaves are used for a purpose distinct from
401- // representing individual Taproot Assets.
402- AltLeaves []asset.AltLeaf [asset.Asset ]
403396}
404397
405398// Copy creates a deep copy of the VInput.
@@ -417,8 +410,7 @@ func (i *VInput) Copy() *VInput {
417410 // We never expect the individual fields of the proof to change
418411 // while it is assigned to a virtual input. So not deep copying
419412 // it here is fine.
420- Proof : i .Proof ,
421- AltLeaves : asset .CopyAltLeaves (i .AltLeaves ),
413+ Proof : i .Proof ,
422414 }
423415}
424416
@@ -427,27 +419,6 @@ func (i *VInput) Asset() *asset.Asset {
427419 return i .asset
428420}
429421
430- // SetAltLeaves asserts that a set of AltLeaves are valid, and updates a VInput
431- // to set the AltLeaves. Setting the input's AltLeaves twice is disallowed.
432- func (i * VInput ) SetAltLeaves (altLeafAssets []* asset.Asset ) error {
433- // AltLeaves can be set exactly once on a VInput.
434- if len (i .AltLeaves ) != 0 {
435- return fmt .Errorf ("%w: input" , ErrAltLeavesAlreadySet )
436- }
437-
438- // Each asset must be a valid AltLeaf, and the set of AltLeaves must be
439- // valid, by not having overlapping keys in the AltCommitment.
440- altLeaves := asset .ToAltLeaves (altLeafAssets )
441- err := asset .ValidAltLeaves (altLeaves )
442- if err != nil {
443- return err
444- }
445-
446- i .AltLeaves = asset .CopyAltLeaves (altLeaves )
447-
448- return nil
449- }
450-
451422// serializeScriptKey serializes the input asset's script key as the PSBT
452423// derivation information on the virtual input.
453424func (i * VInput ) serializeScriptKey (key asset.ScriptKey , coinType uint32 ) {
0 commit comments