The statute makes it unlawful for anyone to promise any employment, position, compensation, contract, appointment, or other benefit to any person as a consideration, favor, or reward for any political activity or for the support of or opposition to any candidate or any political party . . . in connection with any primary election.