Fix types of bitwise-and and bitwise-xor.

Found with random testing.
Factor out grammar to generate well-typed terms with higher probability.

Allows us to test integer-specific functions.
Sometimes generate random integers.
Add random testing for complexes.

Fix a bug it found.
Re-enable testing of hyperbolic trigonometry functions.
Fix type of lcm.

Found using random testing.
Simplify type.