Fixes build on Linux systems with glibc 2.34 and newer.
Upstream: https://github.com/onqtam/doctest
Git SHA: 4d8716f1efc1d14aa736ef52ee727bd4204f4c40
Closes: #235
We need to set Debug Information Format in VS to C7 compatible/ Old style to get all debugging information in obj file which is currently expected by buildcache
- Call GetUserProfileDirectoryW only once for the most of the cases,
since calls to filesystem functions on Windows is expensive.
- Don't allocate memory on heap in most of the cases
- There is no need to replace slashes with backslashes,
since `GetFullPathNameW` returns backslashes
(checked personally on Windows 10).
- Make function work for paths >= MAX_PATH
by performing second call to `GetFullPathNameW`
in case first reported buffer too small
- Don't use `substr` to remove single char
- Don't use `substr` to transform single char to upper case
- Call `GetFinalPathNameByHandleW` only once for the most of the cases
to improve performance since calling filesystem functions on Windows is
expensive
- Use `std::string::compare` which works faster instead of making `substr`
just to compare