“inputA is spendable only together with inputB”
Using signatures, a SIGHASH_GROUP* would trivially solve this. Current discussion seems to favor introspection vs sigs tho.
*notably unimplemented/lacking a proposal so yes this isn’t currently practicable.