From: Burkhard K. <bu...@bu...> - 2000-12-08 00:10:46
|
Andreas Fester > Hi, > > > > I introduced quite some tab diffs, because the original source code > > > did use almost no indentation, making it very hard to read. I use only > > > tabs (no spaces except accidentally) which should expand to whatever the > > > editor has been set to. (8 spaces if vi default is used). I am a bit > > Personally, I started to never use tabs. My Editor (and Emacs should > also be able to handle it that way ;-) ) can be set to use spaces > instead of tabs, and then also inserts spaces for automatic > indentation. The advantage of using spaces only is that it looks the > same in every editor, without having to puzzle with tab settings and > the like. Well, first aim should be to make the sources readable and to do it in a consistent way. There exists a CodingStyle guide imn /usr/src/linux/Documentation which gives precise instructions how to indent. I suggest to use this document at least for ieee12844 modules. From my experience tabs are the easiest way to be consistent among developers (and tabs adhere to the above mentioned guidelines). I think almost any decent editor will expand one tabstop to an 8char space by default, even emacs ;-). Only in case you have played with your editors settings you will get a different appearance. If you are using spaces and you don't check afterwards, you might have accidentially indented in a way you did not intend to use. I guess that's what happend to ieee12844*.c - tabs and spaces mixed. On the other hand I'd have no trouble to use whatever we agree upon as long we come to an agreement. For now, the lack of proper indentation makes reading the sources pretty hard. > > [...] > > I played around with GNU indent a little tonight, and perhaps the best thing > > to do is run "indent -kr -i8" on ieee12844.c with your code changes. It's not > It looks like I missed the original posting you were answering to. If indent would help to achieve proper indentation, I'd be happy to use it. Burkhard -- Burkhard Kohl bu...@bu... |