Support GCC's -Wconversion -Wfloat-conversion -Warith-conversion -Wsign-conversion warnings.

This commit is contained in:
Ion Gaztañaga
2021-10-16 15:56:54 +02:00
parent a4180b9e9f
commit 2eeee6cb4c
23 changed files with 337 additions and 422 deletions
+3 -3
View File
@@ -68,8 +68,8 @@ int main()
{
//Now create an intrusive list in shared memory:
//nodes and the container itself must be created in shared memory
const int MaxElem = 100;
const int ShmSize = 50000;
const std::size_t MaxElem = 100;
const std::size_t ShmSize = 50000;
const char *ShmName = get_shared_memory_name();
{
//Erase all old shared memory
@@ -88,7 +88,7 @@ int main()
pshm_vect->resize(MaxElem);
//Initialize all the nodes
for(int i = 0; i < MaxElem; ++i) (*pshm_vect)[i].set(i);
for(std::size_t i = 0; i < MaxElem; ++i) (*pshm_vect)[i].set((int)i);
//Now create the shared memory intrusive list
intrusive_list_t *plist = shm.construct<intrusive_list_t>(ip::anonymous_instance)();