On Mon, Aug 10, 2015 at 7:34 AM, Jacek Caban <ja...@codeweavers.com> wrote:
> Hi David, > > > > I'm sorry for the delay, I was sure I already replied. The patch looks > mostly good and ready to be committed IMO. There is one minor thing: > > -#ifndef _INTSAFE_H_INCLUDED_ > -#define _INTSAFE_H_INCLUDED_ > +#pragma once > > We use #ifndef guards all over the place. PSDK headers usually use both. > That's find to add the pragma, but please don't delete existing guards. > > Also while I was reviewing the patch, I noticed that MS version doesn't > set output value to 0, but instead to values like ~0. Documentation > specifies this case as invalid value, so whatever we use is fine IMHO. > > Thanks for the work, > Jacek > > >From a very old gcc manual: "The GNU C preprocessor is programmed to notice when a header file uses this particular construct and handle it efficiently. If a header file is contained entirely in a `#ifndef' conditional, then it records that fact. If a subsequent `#include' specifies the same file, and the macro in the `#ifndef' is already defined, then the file is entirely skipped, without even reading it. There is also an explicit directive to tell the preprocessor that it need not include a file more than once. This is called `#pragma once', and was used *in addition to* the `#ifndef' conditional around the contents of the header file. `#pragma once' is now obsolete and should not be used at all." ... not sure what/if changed since then.
------------------------------------------------------------------------------
_______________________________________________ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public