Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   C++ (http://www.velocityreviews.com/forums/f39-c.html)
-   -   GCC and VC++ (http://www.velocityreviews.com/forums/t953037-gcc-and-vc.html)

Rene Ivon Shamberger 10-04-2012 02:11 PM

GCC and VC++
 
I am converting an application from GCC to Visual Studio C++ 10(VS), the express thing from Microsoft.
VS, I get an error msg on this class method does not work, 'cos std::_Ios_Openmode is not a member of the std??!!
void Read( const Glib::ustring& str, std::_Ios_Openmode& )


----------
error C2039: '_Ios_Openmode' : is not a member of 'std'
error C2061: syntax error : identifier '_Ios_Openmode'

how can I fix this problem?

FredK 10-04-2012 02:35 PM

Re: GCC and VC++
 
On Thursday, October 4, 2012 7:11:15 AM UTC-7, Rene Ivon Shamberger wrote:
> I am converting an application from GCC to Visual Studio C++ 10(VS), the express thing from Microsoft. VS, I get an error msg on this class method does not work, 'cos std::_Ios_Openmode is not a member of the std??!! void Read( const Glib::ustring& str, std::_Ios_Openmode& ) ---------- error C2039: '_Ios_Openmode' : is not a member of 'std' error C2061: syntax error : identifier '_Ios_Openmode' how can I fix this problem?


Inspection of the g++ headers shows that _Ios_Openmode, defined in bits/ios_base.h, is an non-standard implementation detail of the g++ iostream library. It should never be directly referenced by user code. The standard way to specify a file mode is using ios::openmode, specified in <fstream>.




Rene Ivon Shamberger 10-04-2012 03:59 PM

Re: GCC and VC++
 
Yes, I understand that, but the deffinition is
//! std API
//! File mode
//! Synonymous with std::ios_base::in
std::_Ios_Openmode read;
So, I using the standard, VC should not have a problem with the std.

Thanks for the help!


All times are GMT. The time now is 11:51 AM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57