[bind10-dev] coding guidelines
Michal 'vorner' Vaner
michal.vaner at nic.cz
Tue Oct 16 09:50:53 UTC 2012
Hello
On Tue, Oct 16, 2012 at 09:40:07AM +0000, Francis Dupont wrote:
> > I'm not sure if we understand each other. What I'm saying is, if
> > you're referring to "local" header (lock.cc includes lock.h or
> > thread.cc includes lock.h, all of them living in one directory),
> > then use " " without any path. If you're using lock.h in the auth
> > server, then use < >, because it's not local file.
>
> => the concern I have about " " is it doesn't say to ignore the -I
> paths, it just changes the order to search is done. More, this order
> change is compiler dependent, e.g., gcc and msvc don't use the same!
> And the C11 standard says if the " " specific search fails the include
> must be interpreted as with < >, so there is no way to "protect" a
> " " include.
Well, it's not only about order. The < > ones do _not_ include the local
directory (or, are not required to). And the " " ones are required to search
them first. So, I'm not saying the behaviour is that " " searches only the local
directory, or whatever. I'm saying that with the usage I described, you should
be safe.
> => anyway there should be something in the guidelines and this must be
> enforced at the first occasion. For instance I am porting bind10 to WIN32
> (cf trac2351) and I can change in
> src/lib/exceptions/exceptions.cc
Yes, there should. I asked to add a topic for today call to agree on it.
Currently, there's no guideline and the code reflects that.
With regards
--
There's the light at the end of the the Windows.
-- Havlik Denis
Michal 'vorner' Vaner
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <https://lists.isc.org/pipermail/bind10-dev/attachments/20121016/b34ba7bb/attachment.bin>
More information about the bind10-dev
mailing list