在ATL中使用STL的问题!

lwg7603 2001-05-22 11:11:00
我在ATL中使用了STL中的string字符串类,编译通过,但有几个warning,不知是何原因?
请高手指教.warning如下:
d:\visual c++\vc98\include\istream(547) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\ostream(234) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\ostream(229) : while compiling class-template member function 'class std::basic_ostream<char,struct std::char_traits<char> > &__thiscall std::basic_ostream<char,struct std::char_traits<char> >::put(char)'
d:\visual c++\vc98\include\ostream(234) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\ostream(229) : while compiling class-template member function 'class std::basic_ostream<unsigned short,struct std::char_traits<unsigned short> > &__thiscall std::basic_ostream<unsigned short,struct std::char_traits
<unsigned short> >::put(unsigned short)'
d:\visual c++\vc98\include\istream(46) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\istream(41) : while compiling class-template member function 'bool __thiscall std::basic_istream<char,struct std::char_traits<char> >::ipfx(bool)'
d:\visual c++\vc98\include\istream(46) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\istream(41) : while compiling class-template member function 'bool __thiscall std::basic_istream<unsigned short,struct std::char_traits<unsigned short> >::ipfx(bool)'
d:\visual c++\vc98\include\xstring(525) : warning C4530: C++ exception handler used, but unwind semantics are not enabled. Specify -GX
d:\visual c++\vc98\include\xstring(521) : while compiling class-template member function 'void __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::_Copy(unsigned int)'
...全文
50 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
lwg7603 2001-05-22
  • 打赏
  • 举报
回复
to luxyi:
Thank you!!!perfect!!!
 
lwg7603 2001-05-22
  • 打赏
  • 举报
回复
to luxyi:
Thank you!!!perfect!!!
 
luxyi 2001-05-22
  • 打赏
  • 举报
回复
在集成环境的菜单中:project->settings->c/c++->category:c++ language->选中enable exception handling

3,245

社区成员

发帖
与我相关
我的任务
社区描述
ATL,Active Template Library活动(动态)模板库,是一种微软程序库,支持利用C++语言编写ASP代码以及其它ActiveX程序。
社区管理员
  • ATL/ActiveX/COM社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧