C++コードをeVC4.0からVisualStudio2008に移植する作業を行っています。ターゲットはWindowsMobile6.1であり、アプリにはWindows Mobile6.0SDKを使用しています。
私たちのコードはeVC4でコンパイルされたときにstlポートを使用しましたが、可能な限りstlポートを引き続き使用したいと思います。
アプリケーションにSTLポート(5.2.1)を組み込むために必要な手順を知っている人はいますか。ソリューションにインクルードディレクトリを設定しましたが(eVC 4.0プロジェクトの場合と同様)、独自のクラスでlist push_backまたはvectorinsertコマンドを使用しようとするとエラー(以下)が発生します(以下はエラーです)。クラス「TriangleBufferElement」を使用)。これらのコマンドは、int、doubleなどのネイティブタイプで機能するようです。
すべてのクラスに適切なコンストラクター、コピーコンストラクター、代入演算子、および比較演算子があり、すべてが正しいように見えることを確認しました。
何か案は?
C:\Program Files\Windows CE Tools\stlport\stl/_construct.h(119) : error C2665: 'operator new' : none of the 2 overloads could convert all the argument types
1> C:\Program Files\Windows Mobile 6 SDK\PocketPC\include\../../../Windows Mobile 6 SDK\PocketPC\Include\Armv4i/new(61): could be 'void *operator new(unsigned int,const std::nothrow_t &) throw()'
1> while trying to match the argument list '(unsigned int, TriangleBufferElement *)'
1> C:\Program Files\Windows CE Tools\stlport\stl/_construct.h(134) : see reference to function template instantiation 'void stlp_std::_Copy_Construct_aux<_Tp>(_Tp *,const _Tp &,const stlp_std::__false_type &)' being compiled
1> with
1> [
1> _Tp=TriangleBufferElement
1> ]
1> C:\Program Files\Windows CE Tools\stlport\stl/_vector.h(381) : see reference to function template instantiation 'void stlp_std::_Copy_Construct<_Tp>(_Tp *,const _Tp &)' being compiled
1> with
1> [
1> _Tp=TriangleBufferElement
1> ]
1> C:\Program Files\Windows CE Tools\stlport\stl/_vector.h(376) : while compiling class template member function 'void stlp_std::vector<_Tp>::push_back(const _Tp &)'
1> with
1> [
1> _Tp=TriangleBufferElement
1> ]
1> c:\srcdevbranch\pointlib\dtmconverter\dtm\dtmreader\.\trianglebuffer.h(47) : see reference to class template instantiation 'stlp_std::vector<_Tp>' being compiled
1> with
1> [
1> _Tp=TriangleBufferElement
1> ]