diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-12-21 16:16:13 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-12-21 16:16:13 +0400 |
commit | f25618f29a65277039a11c021981dab487b96966 (patch) | |
tree | 77afa4c87f0b6e53694c490c9fbea5c30dfe71b5 /source/blender/blenlib/BLI_array.h | |
parent | 915f78af928d4ec0ec8cae5bca2710acee5cf3ea (diff) |
make Node.links return a tuple, this may you can't do socket.links.append() by mistake.
removed RNAMeta mixin class since you cant register subclasses.
also some minor code cleanup
Diffstat (limited to 'source/blender/blenlib/BLI_array.h')
-rw-r--r-- | source/blender/blenlib/BLI_array.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenlib/BLI_array.h b/source/blender/blenlib/BLI_array.h index 6d34b0d48d5..7c8816cb58a 100644 --- a/source/blender/blenlib/BLI_array.h +++ b/source/blender/blenlib/BLI_array.h @@ -106,8 +106,8 @@ ((arr = (void *)_##arr##_static), (_##arr##_count += (num))) \ : \ /* use existing static array or allocate */ \ - ((BLI_array_totalsize(arr) >= _##arr##_count + num) ? \ - (_##arr##_count += num) : \ + (LIKELY(BLI_array_totalsize(arr) >= _##arr##_count + num) ? \ + (_##arr##_count += num) : /* UNLIKELY --> realloc */ \ ( \ (void) (_##arr##_tmp = MEM_callocN( \ sizeof(*arr) * (num < _##arr##_count ? \ |