Skip to content

Add #ifndef guard for NOMINMAX macro define#232

Closed
kevreco wants to merge 1 commit intoAcademySoftwareFoundation:mainfrom
kevreco:fixes/nominmax-guard
Closed

Add #ifndef guard for NOMINMAX macro define#232
kevreco wants to merge 1 commit intoAcademySoftwareFoundation:mainfrom
kevreco:fixes/nominmax-guard

Conversation

@kevreco
Copy link

@kevreco kevreco commented Mar 3, 2026

Down the line some projects consuming openfx source code defines there own NOMINMAX define via command line.

This result in few warnings like:

warning C4005: 'NOMINMAX': macro redefinition

This MR fixes that.

@garyo
Copy link
Contributor

garyo commented Mar 3, 2026

This makes sense. Better would be to undef it after including windows.h though, to avoid leaking that define into the user's code. Could you update this PR for that? Also you'll need to sign off on it per our DCO requirements. You can just force-push an updated commit to this PR.

@kevreco kevreco closed this Mar 3, 2026
@kevreco kevreco deleted the fixes/nominmax-guard branch March 3, 2026 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants