Fix intellisense on Windows (#3082)

__INTELLISENSE__ is 1 on vs2022 and clang, causing FMT_HAS_INCLUDE, FMT_USE_FCNTL, etc to be 0.
That results in VS and VSCode having a lot of linter errors while code compiles just fine.
This commit is contained in:
VinaCC 2022-09-05 20:50:06 +02:00 committed by GitHub
parent b98ffb7dbd
commit 1feb430faa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -69,9 +69,7 @@
# define FMT_HAS_FEATURE(x) 0
#endif
#if (defined(__has_include) || FMT_ICC_VERSION >= 1600 || \
FMT_MSC_VERSION > 1900) && \
!defined(__INTELLISENSE__)
#if defined(__has_include) || FMT_ICC_VERSION >= 1600 || FMT_MSC_VERSION > 1900
# define FMT_HAS_INCLUDE(x) __has_include(x)
#else
# define FMT_HAS_INCLUDE(x) 0