diff options
author | Jesse Yurkovich <jesse.y@gmail.com> | 2021-11-19 01:32:56 +0300 |
---|---|---|
committer | Jesse Yurkovich <jesse.y@gmail.com> | 2021-11-19 01:32:56 +0300 |
commit | 5ed3a5d0237949411fe403c9a1cbb5a53a685f69 (patch) | |
tree | a7450518d92c735cc17dc3af7fb149f02b7c124b /source/blender/blenloader | |
parent | 3f288e94140c3520dc88959bcae6af675f299318 (diff) |
Cleanup: Add an empty() method to RNA's CollectionRef class
The existing RNA CollectionRef class only offers a length() operation
which is sometimes used for checking if the collection is empty. This is
inefficient for certain collection types which do not have a native
length member; the entire list is iterated to find the count.
This patch creates an explicit empty() method to be used in such cases
for better semantics. Additionally, many collection types will behave
more efficiently when using the new method instead of checking length.
Making use of the new method will follow separately.
Differential Revision: https://developer.blender.org/D12314
Diffstat (limited to 'source/blender/blenloader')
0 files changed, 0 insertions, 0 deletions