diff --git a/include/sol/stack_core.hpp b/include/sol/stack_core.hpp index e3471120..75a406f8 100644 --- a/include/sol/stack_core.hpp +++ b/include/sol/stack_core.hpp @@ -115,7 +115,7 @@ namespace sol { // If all types are `good enough`, simply calculate alignment in case of the worst allocator std::size_t worst_required_size = 0; for (std::size_t ptr = 0; ptr < max_arg_alignment; ptr++) { - worst_required_size = std::max(worst_required_size, aligned_space_for(ptr)); + worst_required_size = (std::max)(worst_required_size, aligned_space_for(ptr)); } return worst_required_size; }