Gay discrimination vote highlights GOP's ideological struggle