diff --git a/libsrc/core/archive.hpp b/libsrc/core/archive.hpp index d56e3f7f..3bab01f3 100644 --- a/libsrc/core/archive.hpp +++ b/libsrc/core/archive.hpp @@ -947,9 +947,9 @@ namespace ngcore template Archive& ApplyHash(T val) { - auto n = sizeof(T); + size_t n = sizeof(T); char* pval = (char*)&val; - for(int i = 0; i < n; i++) + for(size_t i = 0; i < n; i++) { h[offset++] ^= pval[i]; offset %= 8; diff --git a/libsrc/core/array.hpp b/libsrc/core/array.hpp index 752f6f64..d47e4b78 100644 --- a/libsrc/core/array.hpp +++ b/libsrc/core/array.hpp @@ -40,7 +40,7 @@ namespace ngcore }; template - ostream & operator<< (ostream & ost, Tuple tup) + ostream & operator<< (ostream & ost, Tuple /* tup */) { return ost; } @@ -1227,7 +1227,7 @@ namespace ngcore template - size_t ArraySize (Tuple tup) + size_t ArraySize (Tuple /* tup */) { return 0;} template @@ -1240,7 +1240,7 @@ namespace ngcore template - void StoreToArray (FlatArray a, Tuple tup) { ; } + void StoreToArray (FlatArray /* a */, Tuple /* tup */) { ; } template void StoreToArray (FlatArray a, Tuple tup) diff --git a/libsrc/core/localheap.hpp b/libsrc/core/localheap.hpp index 75de3c87..bc295e79 100644 --- a/libsrc/core/localheap.hpp +++ b/libsrc/core/localheap.hpp @@ -198,9 +198,9 @@ public: return reinterpret_cast (oldp); } - virtual void Delete(void* p) {} + virtual void Delete(void* /* p */) {} - virtual void ArrayDelete(void* p) {} + virtual void ArrayDelete(void* /* p */) {} private: /// #ifndef __CUDA_ARCH__ @@ -211,7 +211,7 @@ public: public: /// free memory (dummy function) - NETGEN_INLINE void Free (void * data) throw () + NETGEN_INLINE void Free (void * /* data */) throw () { ; } diff --git a/libsrc/core/profiler.hpp b/libsrc/core/profiler.hpp index 208b7a4e..d49b6543 100644 --- a/libsrc/core/profiler.hpp +++ b/libsrc/core/profiler.hpp @@ -438,21 +438,21 @@ namespace ngcore #else // NETGEN_TRACE_MEMORY public: MemoryTracer() {} - MemoryTracer( std::string name ) {} + MemoryTracer( std::string /* name */ ) {} template - MemoryTracer( std::string name, TRest & ... ) {} + MemoryTracer( std::string /* name */, TRest & ... ) {} - void Alloc(size_t size) const {} - void Free(size_t size) const {} + void Alloc(size_t /* size */) const {} + void Free(size_t /* size */) const {} void Swap(...) const {} int GetId() const { return 0; } template void Track(TRest&...) const {} - static std::string GetName(int id) { return ""; } + static std::string GetName(int /* id */) { return ""; } std::string GetName() const { return ""; } - void SetName(std::string name) const {} + void SetName(std::string /* name */) const {} #endif // NETGEN_TRACE_MEMORY }; } // namespace ngcore diff --git a/libsrc/core/table.hpp b/libsrc/core/table.hpp index 7471b6a3..34f40c93 100644 --- a/libsrc/core/table.hpp +++ b/libsrc/core/table.hpp @@ -192,7 +192,7 @@ namespace ngcore using FlatTable::operator[]; - NETGEN_INLINE void StartMemoryTracing (int mem_id) + NETGEN_INLINE void StartMemoryTracing (int /* mem_id */) { mt.Alloc(GetMemUsage()); } diff --git a/libsrc/core/taskmanager.hpp b/libsrc/core/taskmanager.hpp index d9239be9..7025ce3d 100644 --- a/libsrc/core/taskmanager.hpp +++ b/libsrc/core/taskmanager.hpp @@ -1068,11 +1068,11 @@ public: { static Timer timer("ComputeColoring - "+Demangle(typeid(Tmask).name())); RegionTimer rt(timer); static_assert(sizeof(unsigned int)==4, "Adapt type of mask array"); - auto n = colors.Size(); + size_t n = colors.Size(); Array mask(ndofs); - int colored_blocks = 0; + size_t colored_blocks = 0; // We are coloring with 32 colors at once and use each bit to mask conflicts unsigned int check = 0; diff --git a/libsrc/core/xbool.hpp b/libsrc/core/xbool.hpp index 2063ebf7..fd0da95e 100644 --- a/libsrc/core/xbool.hpp +++ b/libsrc/core/xbool.hpp @@ -20,12 +20,12 @@ namespace ngcore public: xbool (bool b) : state(b ? 2 : 0) { ; } - xbool (TMAYBE x) : state(1) { ; } + xbool (TMAYBE /* x */) : state(1) { ; } xbool () = default; xbool (const xbool &) = default; xbool & operator= (bool b) { state = b ? 2 : 0; return *this; } - xbool & operator= (TMAYBE x) { state = 1; return *this; } + xbool & operator= (TMAYBE /* x */) { state = 1; return *this; } bool IsTrue () const { return state == 2; } bool IsMaybe () const { return state == 1; }