The evolutionary history and activity of a gain-of-function polymorphism in a human antiviral gene