DOC: domain/return type documented as Interval but should be Set in continuous_domain/function_range
Author: sonusharma6-dsaCreated Sep 16, 2026Updated Sep 16, 2026
Was reading through continuous_domain and function_range in sympy/calculus/util.py and noticed the docstrings say domain is a :py:class:~.Interval``, but that doesn't match the examples right below it — the very first one passes S.Reals, which is a Set, not an Interval.
Same thing happens in the Returns section of continuous_domain — it says Interval, but the function can return a Union of intervals or a FiniteSet too, which aren't strictly Interval.
Pretty sure both should just say :py:class:~.Set`` instead. Happy to send a small PR fixing this if that sounds right.
Source: sympy/sympy