(anal) Q: Are there any coding styles or development guidelines?
- From
- Klaus Robert Suetterlin <robert@mpe.mpg.de>
- Date
- Apr 22, 2005, 15:58 UTC
- Message-ID
- <20050422155845.GC52771@xdt04.mpe-garching.mpg.de>
- In-Reply-To
- <Pine.LNX.4.58.0504220838340.2344@ppc970.osdl.org>
I'm currently doing a source audit of the git core components. Mainly I want to check if I can spot some left over memory leaks.
Unfortunately ;) I didn't find any so far (after reading five files).
Still I did find quite a lot of stuff that lint would most likely complain about. Like not checking return values. Should this be fixed now or isn't it time to do the cleanup, yet?
I also found several literal copies of the same function including function name, parameter list, etc. Wouldn't it be better do clean those up and put them in a utility.{c,h} file? A similar problem is the continous reimplementation of linked lists, dynamic memory, smart strings / vectors, etc. And then there are some stale files (i.e. revision.*) that the Changelog already mentions as removed, but which are still active in HEAD.
I am a little reluctant to do the work, as the code still changes so fast I do not really know if code I fix will still be there tomorrow.
Also I do not know if there is any notion of coding style published somewhere. I only noticed, that the code does not look like anything I'd have written and seems to follow some general principle.
Kind regards,
--Robert Suetterlin (robert@mpe.mpg.de) phone: (+49)89 / 30000-3546 fax: (+49)89 / 30000-3950