Using replaceable operating system API plugins #120635
Labels
C-discussion
Category: Discussion or questions that doesn't represent real issues.
O-windows
Operating system: Windows
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
Currently, I see that Mutex locks on Windows using TryAcquireSRWLockExclusive and AcquireSRWLockExclusive. The former only supports Windows 7 and above, while the latter supports Windows Vista and above.
Using the APIs of both resulted in compatibility only with Windows 7 and not supporting Windows XP, Windows 2003, Windows 2008. if you want run this exe will be
can't find TryAcquireSRWLockExclusive on kernel32.dll
see this example :
What I want to ask is why not move the API called by the operating system to a replaceable plugin, such as the toolchain toolchain in Rust, so This is more flexible, and we can build our own toolchain that is compatible with older versions of the operating system
The text was updated successfully, but these errors were encountered: