隐式转换失去整数精度

时间:2018-11-27 01:52:15

标签: xcode c++11

全部

我正在尝试编写跨平台代码以在Windows,* nix和OSX上进行编译。前两个编译正常,但Xcode给出以下警告:

Implicit conversion looses integer precision "std::map<int, std::vector<Foo *>>::size_type (aka 'unsigned long') to std::__t::map<int, std::__t::vector<Foo *, std::__t::allocator<Foo *> >, std::__t::less<int>, std::__t::allocator<std::__t::pair<const int, std::__t::vector<Foo *, std::__t::allocator<Foo *> > > >::key_type (aka int)

仅仅是在Foo中编写一个operator <()函数的问题吗?

TIA !!

0 个答案:

没有答案
相关问题