Skip to content

Redefinition of NOMINMAX causes warning in Windows #3964

Closed
@DougRogers

Description

In platform.h for Windows, there is a definition of NOMINMAX that causes warnings when it is already defined.

//Avoid min and max being defined
#if defined(_WIN32)
#define NOMINMAX
#endif

Furthermore, right above it is another definition of NOMINMAX correctly wrapped by an ifdef

#if defined(_WIN32)
#    ifndef WIN32_LEAN_AND_MEAN
#        define WIN32_LEAN_AND_MEAN
#    endif
#    ifndef VC_EXTRALEAN
#        define VC_EXTRALEAN
#    endif
#    ifndef NOMINMAX
#        define NOMINMAX
#    endif
#    ifndef NOGDI
#        define NOGDI
#    endif
#    include <windows.h>
#endif


Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions