Compile warning with fstream.h

If I include <fstream.h> in a C++ program and try to compile with
warning set high, I get warnings from xlocale about local variables
shadowing class members with the same name.

If I were to write code like this, I would want the compiler to warn
me about the possible mistake. So I’d rather not disable this warning.

The variables and line numbers in question are:
_Off: 331
_Refs: 382, 453, 458, 552, 557, 734, 805, 810, 984 & 994.

And again I see in xlocnum:
_Refs: 45, 50, 158, 163, 631, 636

And in ios:
_Except: 32, 41

And in istream:
_Noinit: 23
_Ctype: 740, 827

All of these are in /usr/include/cpp.

Is there a chance in hell that the header files will get fixed?


Bill Caroselli – Q-TPS Consulting
1-(708) 308-4956 <== Note: New Number
qtps@earthlink.net

Apparently it is fixed in 6.21B
Lacking a sample, I just included everything from
/usr/include/cpp and compiled ‘QCC -Wall -c testerooni.cc’
No warnings.

Bill Caroselli wrote:

If I include <fstream.h> in a C++ program and try to compile with
warning set high, I get warnings from xlocale about local variables
shadowing class members with the same name.

If I were to write code like this, I would want the compiler to warn
me about the possible mistake. So I’d rather not disable this warning.

The variables and line numbers in question are:
_Off: 331
_Refs: 382, 453, 458, 552, 557, 734, 805, 810, 984 & 994.

And again I see in xlocnum:
_Refs: 45, 50, 158, 163, 631, 636

And in ios:
_Except: 32, 41

And in istream:
_Noinit: 23
_Ctype: 740, 827

All of these are in /usr/include/cpp.

Is there a chance in hell that the header files will get fixed?

I am running 6.21B.

I will post a short complete example.

Garry Turcotte <garry@qnx.com> wrote:
GT > Apparently it is fixed in 6.21B
GT > Lacking a sample, I just included everything from
GT > /usr/include/cpp and compiled ‘QCC -Wall -c testerooni.cc’
GT > No warnings.

GT > Bill Caroselli wrote:

If I include <fstream.h> in a C++ program and try to compile with
warning set high, I get warnings from xlocale about local variables
shadowing class members with the same name.

If I were to write code like this, I would want the compiler to warn
me about the possible mistake. So I’d rather not disable this warning.

The variables and line numbers in question are:
_Off: 331
_Refs: 382, 453, 458, 552, 557, 734, 805, 810, 984 & 994.

And again I see in xlocnum:
_Refs: 45, 50, 158, 163, 631, 636

And in ios:
_Except: 32, 41

And in istream:
_Noinit: 23
_Ctype: 740, 827

All of these are in /usr/include/cpp.

Is there a chance in hell that the header files will get fixed?


Bill Caroselli – Q-TPS Consulting
1-(708) 308-4956 <== Note: New Number
qtps@earthlink.net

I don’t know. I kind of moved on to another project. I’ll try it
again now that I understand a little more about what I was doing.


Garry Turcotte <garry@qnx.com> wrote:
GT > Has this been resolved?

GT > Bill Caroselli wrote:

I am running 6.21B.

I will post a short complete example.

Garry Turcotte <> garry@qnx.com> > wrote:
GT > Apparently it is fixed in 6.21B
GT > Lacking a sample, I just included everything from
GT > /usr/include/cpp and compiled ‘QCC -Wall -c testerooni.cc’
GT > No warnings.

GT > Bill Caroselli wrote:

If I include <fstream.h> in a C++ program and try to compile with
warning set high, I get warnings from xlocale about local variables
shadowing class members with the same name.

If I were to write code like this, I would want the compiler to warn
me about the possible mistake. So I’d rather not disable this warning.

The variables and line numbers in question are:
_Off: 331
_Refs: 382, 453, 458, 552, 557, 734, 805, 810, 984 & 994.

And again I see in xlocnum:
_Refs: 45, 50, 158, 163, 631, 636

And in ios:
_Except: 32, 41

And in istream:
_Noinit: 23
_Ctype: 740, 827

All of these are in /usr/include/cpp.

Is there a chance in hell that the header files will get fixed?

\


Bill Caroselli – Q-TPS Consulting
1-(708) 308-4956 <== Note: New Number
qtps@earthlink.net

Has this been resolved?

Bill Caroselli wrote:

I am running 6.21B.

I will post a short complete example.

Garry Turcotte <> garry@qnx.com> > wrote:
GT > Apparently it is fixed in 6.21B
GT > Lacking a sample, I just included everything from
GT > /usr/include/cpp and compiled ‘QCC -Wall -c testerooni.cc’
GT > No warnings.

GT > Bill Caroselli wrote:

If I include <fstream.h> in a C++ program and try to compile with
warning set high, I get warnings from xlocale about local variables
shadowing class members with the same name.

If I were to write code like this, I would want the compiler to warn
me about the possible mistake. So I’d rather not disable this warning.

The variables and line numbers in question are:
_Off: 331
_Refs: 382, 453, 458, 552, 557, 734, 805, 810, 984 & 994.

And again I see in xlocnum:
_Refs: 45, 50, 158, 163, 631, 636

And in ios:
_Except: 32, 41

And in istream:
_Noinit: 23
_Ctype: 740, 827

All of these are in /usr/include/cpp.

Is there a chance in hell that the header files will get fixed?
\