python-pillow / Pillow

Python Imaging Library (Fork)
https://python-pillow.org
Other
12.32k stars 2.23k forks source link

Added default values for _Tile offset and args #8553

Open radarhere opened 1 week ago

radarhere commented 1 week ago

https://github.com/python-pillow/Pillow/blob/5bff2f3b2894ec6923c590d0c37b18177d0634bd/src/PIL/ImageFile.py#L98-L102

Adding defaults of 0 for offset and None for args will allow small simplifications to some instantiations of ImageFile._Tile.

An args value of (mode, 0, 1) can also be replaced by mode https://github.com/python-pillow/Pillow/blob/5bff2f3b2894ec6923c590d0c37b18177d0634bd/src/PIL/ImageFile.py#L221-L222