Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[overlay] reset implementation and simplify with lovely preprocessor macros #2379

Merged
merged 4 commits into from
Nov 9, 2022

Conversation

myk002
Copy link
Member

@myk002 myk002 commented Nov 8, 2022

  • removes all logic from overlay and leaves only a plugin skeleton that interposes all the viewscreens
  • adds framework for preprocessor macro-based list transformations:
    • MAP applies a function macro to a list of arguments
    • MAP_JOIN applies a function macro to a list of arguments and inserts a given separator between the results
    • MAP_LIST a specialization of MAP_JOIN with a comma as the separator

does the absorbed code need a LICENSE entry?

@myk002
Copy link
Member Author

myk002 commented Nov 8, 2022

It appears that windows does not like the preprocessor macros. I'll have to research that a bit to see if there's something I can do for compatibility.

OTOH, we're about to update the windows compiler for the steam version, right? That might fix the problem too.

@myk002
Copy link
Member Author

myk002 commented Nov 8, 2022

This appears to be a known issue. Fixed in VS 2019 with /Zc:preprocessor and in VS 2017 15.8 with /experimental:preprocessor (see here). We could enable the latter compilation option with our current build, I believe.

@myk002
Copy link
Member Author

myk002 commented Nov 9, 2022

it appears that our MSVC toolchain is too old even for the experimental flag. I'll revert the macros for now and revisit once we've updated our toolchain for the steam release.

@myk002 myk002 force-pushed the myk_overlay_reset_and_simplify branch from f87c8d0 to dce312b Compare November 9, 2022 17:38
@myk002 myk002 merged commit 8a47c10 into DFHack:develop Nov 9, 2022
@myk002 myk002 deleted the myk_overlay_reset_and_simplify branch November 9, 2022 18:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

1 participant