Fix warnings when building in RELEASE mode

on Windows and on Mac (for the latter this PR does fix some, but by far not all warnings, esp. none of the overload related ones, well, it fixed one of these and, hopefully, all the others, but it is too easy to miss the tree in the forest here)