This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: #include <new.h> now causes a warning


On Fri, Aug 10, 2001 at 01:03:46PM -0700, Joe Buck wrote:
> The original report claimed that this was so (that math.h would get a
> warning), and I did not verify it myself as I've been testing the 3.0
> branch, not the trunk.

I never said that including math.h would trigger this warning.
Please re-read:
http://gcc.gnu.org/ml/gcc/2001-08/msg00588.html

> 
> So: Which headers issue the warning?

I saw this problem by including new.h.
Under gcc 3.1, I also see this warning triggered by
including iostream.h.  Basically, any header file 
in the "backward" directory will trigger this warning:
algo.h, fstream.h, iomanip.h, iostream.h, etc., etc.

For example, in gcc 3.1, new.h consists of the following:

#ifndef _CPP_BACKWARD_NEW_H
#define _CPP_BACKWARD_NEW_H 1
 
#include "backward_warning.h"
#include <new>
 
using std::bad_alloc;
using std::nothrow_t;
using std::nothrow;
using std::new_handler;
using std::set_new_handler;
 
#endif


Is this #include "backward_warning.h" present in the
header files in the 3.0.1 branch, or is only in the 3.1 branch?

-- 
Craig Rodrigues        
http://www.gis.net/~craigr    
rodrigc@mediaone.net          


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]