On Wed, 28 May 2008 17:46:36 +0200, Enrico Tröger enrico.troeger@uvena.de wrote:
On Tue, 27 May 2008 15:34:02 +0100, Nick Treleaven nick.treleaven@btinternet.com wrote:
On Mon, 26 May 2008 13:03:21 +0100 Nick Treleaven nick.treleaven@btinternet.com wrote:
On Sun, 25 May 2008 22:20:01 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
...
I started using the underscores because I thought this is common practise (at least I read a lot of code where underscores are used) and at some point there were problems if structs and types had the same name, so the easiest solution was to prefix the struct name with
Do you remember what problems there were?
Just to add info:
Although I haven't yet found a link to the relevant part of the ISO C90 standard, I've read elsewhere that struct names and typedef names have separate namespaces.
http://blogs.msdn.com/oldnewthing/archive/2008/03/26/8336829.aspx
So for new code (such as our API) it ought to be fine to use the same name for each. Also I'm pretty sure I'd done this a few times already
Ok, so let's use the same names for structs and typedefs.
Done (except I forgot one).
Regards, Enrico