lkml.org 
[lkml]   [2002]   [Dec]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Indention - why spaces?
> IMHO and in my personal projects I use the following indenting rules:
>
> 1) use TABs for _indentation_
> 2) use SPACEs for aligning
>
> here is an exaple:
>
><tab><tab>if (cond) {
><tab><tab><tab>dosometing;
><tab><tab><tab>printf("This is foo: '%s', and this bar: '%d'",
><tab><tab><tab> foo, bar);

BTW, this practice is codified in Solaris developer's guidelines.
They even have a perl script called "hdrchk" which is run before
commits and tells about violations. Actually, the Sun requirement
is to have exactly 4 spaces, but it sounds a little too anal to me.

-- Pete
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:32    [W:0.115 / U:3.092 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site