This repository has been archived on 2023-10-09. You can view files and clone it, but cannot push or open issues or pull requests.
Files
blender-archive/source/blender/python/intern
Campbell Barton d8582d966f Fix slicing with negative indices
Negative indices that remained negative after adding the sequence length
caused incorrect slicing.

With the default scene for example:

   bpy.context.scene.objects[-4:2]

Gave a different result to:

   tuple(bpy.context.scene.objects)[-4:2]

Clamp indices above zero so loops that step forward works as intended.
2021-08-05 16:44:03 +10:00
..
2021-07-30 16:16:38 +10:00
2021-06-13 14:47:01 +10:00
2020-09-02 15:58:44 +10:00
2021-08-05 16:44:03 +10:00
2021-06-22 10:54:50 -07:00