STL include file guard names

Ed Rice-Senior Programmer PGS Software Perth ed.rice@pgs.com
Fri Jul 30 07:43:00 GMT 2004


Hi,

I noticed that the STL header file guard macro names in the version of 
libstc++ that ships with gcc 3.4.1 have changed compared to those that 
shipped with gcc 3.3.3.  For example in include/c++/3.4.1/bits/stl_set.h 
the header guard is

#ifndef _SET_H
#define _SET_H 1

while with gcc 3.3.3 include/c++/3.3.3/bits/stl_set.h used header guards

#ifndef __GLIBCPP_INTERNAL_SET_H
#define __GLIBCPP_INTERNAL_SET_H

Is there a reason for the change? It seems to me that the 3.3.3 style 
has the benefit of being much less likely to clash with other libraries.

Ed
(ed.rice@pgs.com)



More information about the Libstdc++ mailing list