From 9cba13ca5d233a4e1a7068f3f5ed5836a081dcc0 Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Wed, 16 Mar 2011 02:08:34 -0500 Subject: standardize brace placement in struct definitions In a struct definitions, unlike functions, the prevailing style is for the opening brace to go on the same line as the struct name, like so: struct foo { int bar; char *baz; }; Indeed, grepping for 'struct [a-z_]* {$' yields about 5 times as many matches as 'struct [a-z_]*$'. Linus sayeth: Heretic people all over the world have claimed that this inconsistency is ... well ... inconsistent, but all right-thinking people know that (a) K&R are _right_ and (b) K&R are right. Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- merge-recursive.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'merge-recursive.c') diff --git a/merge-recursive.c b/merge-recursive.c index 16c2dbeab9..42d52cb5bc 100644 --- a/merge-recursive.c +++ b/merge-recursive.c @@ -83,10 +83,8 @@ struct rename_df_conflict_info { * Since we want to write the index eventually, we cannot reuse the index * for these (temporary) data. */ -struct stage_data -{ - struct - { +struct stage_data { + struct { unsigned mode; unsigned char sha[20]; } stages[4]; @@ -403,8 +401,7 @@ static void make_room_for_directories_of_df_conflicts(struct merge_options *o, } } -struct rename -{ +struct rename { struct diff_filepair *pair; struct stage_data *src_entry; struct stage_data *dst_entry; @@ -717,8 +714,7 @@ static void update_file(struct merge_options *o, /* Low level file merging, update and removal */ -struct merge_file_info -{ +struct merge_file_info { unsigned char sha[20]; unsigned mode; unsigned clean:1, -- cgit v1.2.1