From 0df127697c2bba569fe6ac01db1792494ccb4220 Mon Sep 17 00:00:00 2001 From: ytwei Date: Mon, 24 Aug 2026 20:55:56 +0800 Subject: [PATCH] =?UTF-8?q?docs:=20describe=20Int=20and=20Float=20bounds?= =?UTF-8?q?=20=F0=9F=A4=96=F0=9F=8D=86=20(#357)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/source/trait_types.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/source/trait_types.rst b/docs/source/trait_types.rst index 9a892fd0b..f15484256 100644 --- a/docs/source/trait_types.rst +++ b/docs/source/trait_types.rst @@ -18,6 +18,10 @@ Numbers An integer trait. + ``Int`` accepts ``min`` and ``max`` keyword arguments to constrain values + to inclusive lower and upper bounds. Both default to ``None``. The + effective constructor options are ``Int(..., *, min=None, max=None)``. + .. class:: Integer @@ -34,6 +38,11 @@ Numbers .. autoclass:: Float + A float trait. ``Float`` accepts ``min`` and ``max`` keyword arguments to + constrain values to inclusive lower and upper bounds. They default to + ``-inf`` and ``inf``, respectively. The effective constructor options are + ``Float(..., *, min=-inf, max=inf)``. + .. autoclass:: Complex .. class:: CInt