tfc / pprintpp

Typesafe Python Style Printf Formatting for C++
MIT License
233 stars 12 forks source link

Windows , VisualStudio2019 solution #11

Closed DBJDBJ closed 5 years ago

DBJDBJ commented 5 years ago

There is nothing "better" in my repo :) It is just MSVC compatible. What is worth mentioning, that I changed is:

-- #define AUTOFORMAT is here inside lambda -- pprintpp::autoformat<> str method is changed to constexpr

All works fine with MSVC, within the limits of MSVC capabilities.

What might be named "essential" for WIN environment is wchar_t handling. And consequently to that wprintf targeting ...

DBJDBJ commented 5 years ago

Why this reshuffle in my repo? Because I am using this as a git submodule ... so headers are simply in the front, with everything else hidden in the test folder ...

DBJDBJ commented 5 years ago

Am I, hyperproductive crazy chipmunk? Perhaps I am :)

@tfc said in a comment "for safety reasons" string will require {s} to print as strings, not as pointers. I was so bold to change that; perhaps in a safe way. Please comment.

In any case, VS2019 has no issues with both MSVC and CLANG. All compiles and runs. Still, MSVC can not take that longer expression in test_1 ...

tfc commented 5 years ago

Wow, that was quick.

I hoped however, that in a pull request i could inspect only the changes that you did. In the current representation everything is like "removed everything and re-added with new structure" and the actual changes are somehow hidden in that. Is it possible to present the changes in a way that unchanged lines do not show up in the pull request?

Not only for review i consider this important but also for future rebasing. If i ever want to apply changes to pprintpp, i will of course try to rebase the windows branch on top of those new changes and then have some CI run on it to check if this breaks the windows side of it. With the current presentation (deleting all files and creating new ones with new structure) this workflow is impossible, leaving us with the task to manually implement all changes twice.

tfc commented 5 years ago

Also: Is it necessary to remove the cmake files? I think cmake works in windows just fine and we should leave the possibilities open for users if they use cmake or the visual studio build environment. As i understand, your code changes are needed for the visual C compiler, while the visual c solution files etc. are a nice addon so people can easier use it in their IDE.

Removing the LICENSE file is something that i would certainly not want.

DBJDBJ commented 5 years ago

re-forking