bpo-37812: Make the small-int alloc optimization unconditional. by gnprice · Pull Request #15203 · python/cpython
I think it is worthwhile to mention that this range is inclusive. Otherwise, users might assume that the maximum is 255 instead of 256, or that the minimum is -4 instead of -5. I've seen this range most commonly notated with [-5, 257), but I think adding "(inclusive)" after it is probably more appropriate and easy to understand for a news entry.
| values from -5 to 256 are pre-initialized rather than constructed on demand. | |
| values from -5 to 256 (inclusive) are pre-initialized rather than constructed on demand. |