protobuf-c/: gratuitous style changes
dave's original style drives me crazy. reformat the C code in protobuf-c/ with "indent -kr -i8" and manually reflow for readability. try to fit most lines in 80 columns, but due to the lengthy type and function names in protobuf-c, enforcing an 80 column rule would result in a lot of cramped statements, so try to fit lines in up to 100 columns if it would improve readability. (e.g., one <=100 column line is probably better than 3-4 <=80 column lines.) ultimately i'd like to adopt most of the recommendations in the linux coding style: https://www.kernel.org/doc/Documentation/CodingStyle. this commit gets us most of the kernel indentation and comment coding style recommendations. later commits will tackle style recommendations that require more intrusive changes: breaking up large functions, replacing macros that affect control flow (e.g., DO_ALLOC). this will hopefully facilitate review and make the code base easier to maintain. i ran the old and new versions of protobuf-c.c through something like: gcc -S -D__PRETTY_FUNCTION__=0 -D__FILE__=0 -D__LINE__=0 -Wall -O0 \ -o protobuf-c.S -c protobuf-c.c and reviewed the diffs of the assembly output to spot any functions that changed, and went back to make sure that any differences were functionally equivalent.
Showing
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment