{W}{U}{B}{R}{G}: Exile target permanent. If Legacy Weapon would be put into a graveyard from anywhere, reveal Legacy Weapon and shuffle it into its owner's library instead.
In a single blinding flash, Yawgmoth was obliterated, and Urza could finally rest.