[PATCH] uncrustify.cfg: label indent, some known types, not, # and ##
On Tue, 24 Jan 2012 22:55:59 +0200, Tomi Ollila wrote: > Adjusted some uncrustify variables to get closer to prevailing style: > pushed. d
[PATCH] uncrustify.cfg: label indent, some known types, not, # and ##
Adjusted some uncrustify variables to get closer to prevailing style: * Label indent (for goto) relative to current indentation. * Eegistered GMimeObject and mime_node_t being as types. * Space after ! (not) operator. * No space after 'stringify' (#) preprosessor token. * No spacing change around ## (option not versatile enough). There are at least 3 cases where attention needs to be paid: * If there is newline between function name and open paren in function call, the paren (and args) are indented too far right. * #define HOUR (60 *MINUTE) -- i.e. no space after star (*). * void (*foo)(args) -- i.e no space between (name) and (args). --- devel/uncrustify.cfg | 11 +-- 1 files changed, 9 insertions(+), 2 deletions(-) diff --git a/devel/uncrustify.cfg b/devel/uncrustify.cfg index 1dbc5e4..d8075ba 100644 --- a/devel/uncrustify.cfg +++ b/devel/uncrustify.cfg @@ -16,8 +16,7 @@ input_tab_size= 8 # original tab size output_tab_size= 8 # new tab size indent_columns = 4 -indent_label = 2 # pos: absolute col, neg: relative column - +indent_label = -2# pos: absolute col, neg: relative column # # inter-symbol newlines @@ -55,6 +54,11 @@ nl_after_struct = 0 # mod_full_brace_do= remove# "do a--; while ();" vs "do { a--; } while ();" # mod_full_brace_while = remove# "while (a) a--;" vs "while (a) { a--; }" +# +# Extra types used in notmuch source. +# (add more on demand) + +type GMimeObject mime_node_t # # inter-character spacing options @@ -63,6 +67,9 @@ nl_after_struct = 0 sp_before_ptr_star = force sp_between_ptr_star= remove sp_after_ptr_star = remove +sp_not = force +sp_pp_concat = ignore# XXX 'remove' drops leading space also +sp_pp_stringify= remove # sp _return_paren = force # "return (1);" vs "return(1);" sp_sizeof_paren= force # "sizeof (int)" vs "sizeof(int)" -- 1.7.8.2
[PATCH] uncrustify.cfg: label indent, some known types, not, # and ##
Adjusted some uncrustify variables to get closer to prevailing style: * Label indent (for goto) relative to current indentation. * Eegistered GMimeObject and mime_node_t being as types. * Space after ! (not) operator. * No space after 'stringify' (#) preprosessor token. * No spacing change around ## (option not versatile enough). There are at least 3 cases where attention needs to be paid: * If there is newline between function name and open paren in function call, the paren (and args) are indented too far right. * #define HOUR (60 *MINUTE) -- i.e. no space after star (*). * void (*foo)(args) -- i.e no space between (name) and (args). --- devel/uncrustify.cfg | 11 +-- 1 files changed, 9 insertions(+), 2 deletions(-) diff --git a/devel/uncrustify.cfg b/devel/uncrustify.cfg index 1dbc5e4..d8075ba 100644 --- a/devel/uncrustify.cfg +++ b/devel/uncrustify.cfg @@ -16,8 +16,7 @@ input_tab_size= 8 # original tab size output_tab_size= 8 # new tab size indent_columns = 4 -indent_label = 2 # pos: absolute col, neg: relative column - +indent_label = -2# pos: absolute col, neg: relative column # # inter-symbol newlines @@ -55,6 +54,11 @@ nl_after_struct = 0 # mod_full_brace_do= remove# do a--; while (); vs do { a--; } while (); # mod_full_brace_while = remove# while (a) a--; vs while (a) { a--; } +# +# Extra types used in notmuch source. +# (add more on demand) + +type GMimeObject mime_node_t # # inter-character spacing options @@ -63,6 +67,9 @@ nl_after_struct = 0 sp_before_ptr_star = force sp_between_ptr_star= remove sp_after_ptr_star = remove +sp_not = force +sp_pp_concat = ignore# XXX 'remove' drops leading space also +sp_pp_stringify= remove # sp _return_paren = force # return (1); vs return(1); sp_sizeof_paren= force # sizeof (int) vs sizeof(int) -- 1.7.8.2 ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch