With modern compilers, the lines -((int32_t)(t1 & 1)) & random->tmat in tinymt32.h/c throw warnings of the form
-((int32_t)(t1 & 1)) & random->tmat
^----------------------------------
warning: conversion to ‘uint32_t {aka unsigned int}’ from ‘int’ may change the sign of the result [-Wsign-conversion]
when compiled with -Wsign-conversion.
The same warning is probably also present in tinmy64.h/c.
Maybe an intermediate const variable and an explicit cast can solve this.
With modern compilers, the lines
-((int32_t)(t1 & 1)) & random->tmat
intinymt32.h/c
throw warnings of the formwhen compiled with
-Wsign-conversion
.The same warning is probably also present in
tinmy64.h/c
.Maybe an intermediate
const
variable and an explicit cast can solve this.Used in: https://github.com/alpaka-group/alpaka/pull/579 Diff: https://github.com/alpaka-group/alpaka/commit/783b8f7013b1961a903fc52e4ed56ed7c743b6a6