From 5cac37d8805ec3ceca35834155b84934f3944baf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patryk=20Gawro=C5=84ski?= Date: Sun, 2 Nov 2025 13:00:12 +0100 Subject: [PATCH] Add GetSystemTimePreciseAsFilename According to Microsoft documentation this variant of GetSystemTime guarantiees to get highest posible level of precision (<1us). https://learn.microsoft.com/en-us/windows/win32/api/sysinfoapi/nf-sysinfoapi-getsystemtimepreciseasfiletime --- doc/macro_reference.qbk | 3 +++ include/boost/config/platform/win32.hpp | 1 + 2 files changed, 4 insertions(+) diff --git a/doc/macro_reference.qbk b/doc/macro_reference.qbk index 728b5c8f0..642f3e381 100644 --- a/doc/macro_reference.qbk +++ b/doc/macro_reference.qbk @@ -423,6 +423,9 @@ The platform has the Win32 API type FTIME. [[`BOOST_HAS_GETSYSTEMTIMEASFILETIME`][Platform][ The platform has the Win32 API GetSystemTimeAsFileTime. ]] +[[`BOOST_HAS_GETSYSTEMTIMEPRECISEASFILETIME`][Platform][ +The platform has the Win32 API GetSystemTimePreciseAsFileTime. +]] [[`BOOST_HAS_GETTIMEOFDAY`][Platform][ The platform has the POSIX API `gettimeofday`. ]] diff --git a/include/boost/config/platform/win32.hpp b/include/boost/config/platform/win32.hpp index 450158fba..50b526c2e 100644 --- a/include/boost/config/platform/win32.hpp +++ b/include/boost/config/platform/win32.hpp @@ -72,6 +72,7 @@ # define BOOST_HAS_GETSYSTEMTIMEASFILETIME # define BOOST_HAS_THREADEX # define BOOST_HAS_GETSYSTEMTIMEASFILETIME +# define BOOST_HAS_GETSYSTEMTIMEPRECISEASFILETIME #endif //