Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Get rid of the most repeated warnings

  • Loading branch information...
commit f51b069ac19f31f97642ba6014267a7634442bff 1 parent 44ba4c3
@antialize antialize authored
View
4 tpie/file_accessor/stream_accessor.inl
@@ -38,8 +38,8 @@ void stream_accessor<file_accessor_t>::read_header() {
m_fileAccessor.read_i(&header, sizeof(header));
validate_header(header);
m_size = header.size;
- m_userDataSize = header.userDataSize;
- m_maxUserDataSize = header.maxUserDataSize;
+ m_userDataSize = (size_t)header.userDataSize;
+ m_maxUserDataSize = (size_t)header.maxUserDataSize;
}
template <typename file_accessor_t>
View
3  tpie/file_base.h
@@ -49,6 +49,8 @@ class file_base: public file_base_crtp<file_base> {
/// This is the type of our block buffers. We have one per file::stream
/// distributed over two linked lists.
///////////////////////////////////////////////////////////////////////////
+#pragma warning( push )
+#pragma warning( disable : 4200 )
struct block_t : public boost::intrusive::list_base_hook<> {
memory_size_type size;
memory_size_type usage;
@@ -56,6 +58,7 @@ class file_base: public file_base_crtp<file_base> {
bool dirty;
char data[0];
};
+#pragma warning( pop )
inline void update_size(stream_size_type size) {
m_size = std::max(m_size, size);
View
2  tpie/sort_manager.h
@@ -794,7 +794,7 @@ void sort_manager<T,I,M>::merge_to_output(progress_indicator_base* indicator, tp
// mergeInputStreams is address( address (the first input stream) )
// N.B. nRuns is small, so it is safe to downcast.
single_merge(mergeInputStreams.begin(),
- mergeInputStreams.find(nRuns),
+ mergeInputStreams.find((size_t)nRuns),
outStream, -1, indicator);
if (indicator) indicator->done();
View
2  tpie/stream.h
@@ -482,7 +482,7 @@ memory_size_type stream<T>::memory_usage(memory_size_type count) {
template<class T>
err stream<T>::read_array(T *mm_space, stream_offset_type *len) {
- size_type l=*len;
+ size_type l=(size_t)*len;
err e = read_array(mm_space, l);
*len = l;
return e;
Please sign in to comment.
Something went wrong with that request. Please try again.