The Spanish government of two centuries ago is not the same government as today.
If governments keep up this kind of nonsense, then either
a) NOBODY is going to try and retrieve lost treasures/artifacts anymore; or
b) people will still retrieve them, but in secret; and so whatever historical associations they had will be lost; and and gold and silver will be melted down to conceal its origin.
And # ‘b’ above is far more likely than # ‘a’.