remove unportable min/max macros for better portability