From 03b2371387dcae9f801cabbc1819b1d7e3350829 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 14 Aug 2019 23:29:46 +1000 Subject: Cleanup: move trailing comments to avoid wrapping code Some statements were split across multiple lines because of their trailing comments. In most cases it's clearer to put the comments above. --- source/blender/blenkernel/intern/unit.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'source/blender/blenkernel/intern/unit.c') diff --git a/source/blender/blenkernel/intern/unit.c b/source/blender/blenkernel/intern/unit.c index 375721057c3..e30ea687b13 100644 --- a/source/blender/blenkernel/intern/unit.c +++ b/source/blender/blenkernel/intern/unit.c @@ -734,8 +734,9 @@ static int unit_scale_str(char *str, len_name = strlen(replace_str); len_move = (len - (found_ofs + len_name)) + 1; /* 1+ to copy the string terminator */ - len_num = BLI_snprintf( - str_tmp, TEMP_STR_SIZE, "*%.9g" SEP_STR, unit->scalar / scale_pref); /* # removed later */ + + /* # removed later */ + len_num = BLI_snprintf(str_tmp, TEMP_STR_SIZE, "*%.9g" SEP_STR, unit->scalar / scale_pref); if (len_num > len_max) { len_num = len_max; @@ -748,8 +749,9 @@ static int unit_scale_str(char *str, if (len_move > 0) { /* resize the last part of the string */ - memmove( - str_found + len_num, str_found + len_name, len_move); /* may grow or shrink the string */ + + /* May grow or shrink the string. */ + memmove(str_found + len_num, str_found + len_name, len_move); } if (found_ofs + len_num > len_max) { -- cgit v1.2.3