kernelwernel / VMAware

VM detection library and tool
GNU General Public License v3.0
331 stars 30 forks source link

Windows/MSVC/C++17 update #35

Closed greenozon closed 6 months ago

greenozon commented 6 months ago

All of a sudden was iterating over different C++ standards and hit this case when selected MSVC C++17:

The contents of <bit> are available only with C++20 or later.

inspecting the header in my system I've found the following:

image

as well as some official docs stating that header is indeed part of C++20 standard

Here is a small PR https://github.com/kernelwernel/VMAware/pull/34

also if you don't mind I've added some printouts to end user showing the currently selected compiler standard as well as added support for C++23 standard which was already settled down:

__cplusplus 202302L

Do yo have some plans to start using features/headers from C++23?

kernelwernel commented 6 months ago

Ouch, that's a mistake on my part. Thanks for catching that! :)


also if you don't mind I've added some printouts to end user showing the currently selected compiler standard as well as added support for C++23 standard which was already settled down

That's a pretty good idea, but I've modified it so that it works in a debug build instead of every build version. (note: the cmake debug build is available with cmake -DCMAKE_BUILD_TYPE=Debug fyi)


Do yo have some plans to start using features/headers from C++23?

Maybe, I'm not too familiar with C++23 if I'm being completely honest. I'll try to look around in the C++ standard's docs if I find something interesting to add though.

btw, the PR has been updated with this commit.

kernelwernel commented 6 months ago

merged #34