Declare Expr.terms, GenExpr.children, SumExpr/ProdExpr.constant,
PowExpr.expo and Constant.number as \cdef readonly\, so assigning to
them from Python raises AttributeError. The fields remain writable from
Cython, which is all the internal code needs.
No type annotations are added on purpose: typing the fields (e.g.
\cdef readonly double number\) would change runtime behaviour, as
values would be converted on assignment (a Decimal would become a
float at construction) and repr() would change accordingly.
Only the Cython declaration changes; runtime behaviour, the type stubs
and the mypy baseline are unaffected.
Make the expression classes' internal fields read-only so they cannot be accidentally reassigned or corrupted at runtime, and remove a dead field.