Boost logo

Boost Users :

From: Jim.Hyslop (jim.hyslop_at_[hidden])
Date: 2002-09-26 15:01:14


dick.bridges_at_[hidden] [mailto:dick.bridges_at_[hidden]] wrote:
> Well, that helped A LOT. The only warnings I get now are:
>
> <warnings>
> c:\boost\function.hpp(451) : warning C4097: typedef-name
> 'base_type' used
> as synonym for class-name
> 'function<R,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10>::function1<R,T0,
> `template-parameter268',`template-parameter269',`template-para
> meter270'>'

> The warning level is 4: I'm paranoid. Can these safely be ignored?

According to the MSDN:

---------------- begin quote from MSDN -----------------------------
Compiler Warning (level 3) C4097

typedef-name 'identifier1' used as synonym for class-name 'identifier2'

A typedef name which names a class is itself a class name. However, only a
class declared without a tag can be named. In the following line of code the
typedef name P is promoted to class name but Q is not.

typedef struct { int member; } P, Q;

Q remains a normal typedef name and a synonym for the class.

The following example causes this warning:

typedef struct _T
{
    int i;
} T;

struct U : T
{
    int j;
}; // warning

struct V : _T
{
    int j;
}; // OK

------------------------ end quote from MSDN -------------------------

However, when I tried compiling the example, MSVC6 SP3 at warning level 4
was completely silent. So I'm really confused now - is it a problem or not?
My instinct says no, but I've been wrong before.

-- 
Jim

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net