Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-03-27 05:16:10 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-03-27 05:17:30 +0300
commit9ba948a4859da3308033fa6dc54f74433d7e6a21 (patch)
tree0bd6e95eb59d9af03aa32d925c68e1cbebecc246 /source/blender/blenlib/intern/sort_utils.c
parent337eb8c1de4c57c34520b467d79779153335eecb (diff)
Cleanup: style, use braces for blenlib
Diffstat (limited to 'source/blender/blenlib/intern/sort_utils.c')
-rw-r--r--source/blender/blenlib/intern/sort_utils.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/source/blender/blenlib/intern/sort_utils.c b/source/blender/blenlib/intern/sort_utils.c
index 7166b7753aa..3220f753397 100644
--- a/source/blender/blenlib/intern/sort_utils.c
+++ b/source/blender/blenlib/intern/sort_utils.c
@@ -41,52 +41,52 @@ int BLI_sortutil_cmp_float(const void *a_, const void *b_)
{
const struct SortAnyByFloat *a = a_;
const struct SortAnyByFloat *b = b_;
- if (a->sort_value > b->sort_value) return 1;
- else if (a->sort_value < b->sort_value) return -1;
- else return 0;
+ if (a->sort_value > b->sort_value) { return 1; }
+ else if (a->sort_value < b->sort_value) { return -1; }
+ else { return 0; }
}
int BLI_sortutil_cmp_float_reverse(const void *a_, const void *b_)
{
const struct SortAnyByFloat *a = a_;
const struct SortAnyByFloat *b = b_;
- if (a->sort_value < b->sort_value) return 1;
- else if (a->sort_value > b->sort_value) return -1;
- else return 0;
+ if (a->sort_value < b->sort_value) { return 1; }
+ else if (a->sort_value > b->sort_value) { return -1; }
+ else { return 0; }
}
int BLI_sortutil_cmp_int(const void *a_, const void *b_)
{
const struct SortAnyByInt *a = a_;
const struct SortAnyByInt *b = b_;
- if (a->sort_value > b->sort_value) return 1;
- else if (a->sort_value < b->sort_value) return -1;
- else return 0;
+ if (a->sort_value > b->sort_value) { return 1; }
+ else if (a->sort_value < b->sort_value) { return -1; }
+ else { return 0; }
}
int BLI_sortutil_cmp_int_reverse(const void *a_, const void *b_)
{
const struct SortAnyByInt *a = a_;
const struct SortAnyByInt *b = b_;
- if (a->sort_value < b->sort_value) return 1;
- else if (a->sort_value > b->sort_value) return -1;
- else return 0;
+ if (a->sort_value < b->sort_value) { return 1; }
+ else if (a->sort_value > b->sort_value) { return -1; }
+ else { return 0; }
}
int BLI_sortutil_cmp_ptr(const void *a_, const void *b_)
{
const struct SortAnyByPtr *a = a_;
const struct SortAnyByPtr *b = b_;
- if (a->sort_value > b->sort_value) return 1;
- else if (a->sort_value < b->sort_value) return -1;
- else return 0;
+ if (a->sort_value > b->sort_value) { return 1; }
+ else if (a->sort_value < b->sort_value) { return -1; }
+ else { return 0; }
}
int BLI_sortutil_cmp_ptr_reverse(const void *a_, const void *b_)
{
const struct SortAnyByPtr *a = a_;
const struct SortAnyByPtr *b = b_;
- if (a->sort_value < b->sort_value) return 1;
- else if (a->sort_value > b->sort_value) return -1;
- else return 0;
+ if (a->sort_value < b->sort_value) { return 1; }
+ else if (a->sort_value > b->sort_value) { return -1; }
+ else { return 0; }
}