Proper fix for the min/max template-deduction error on GCC (floor/ceil from global namespace were used instead of std:: equivalents)