Leverage compiler system defines to determine types and sizes for IntelliSense #7355
Labels
Feature Request
internal
Used to opt-out an issue from having GitHub actions applied to it
Language Service
Milestone
Various type and sizes are essentially hard-coded per IntelliSense mode. Some are passed in based on a static file (such as
__SIZE_TYPE__
and__PTRDIFF_TYPE
inlinux.gcc.x64.json
). Some are hard-coded in the IntelliSense parser, based on the compiler and architecture (IntelliSense mode).gcc/clang compilers will output types and sizes when queried, such as:
It's possible that different versions or flavors of the same compiler will output different values for these, even for the same architecture.
For example, both MinGW x64 and cygwin x64 are associated with the windows-gcc-x64 IntelliSense mode, but use different sizes for long.
Some gcc ports to Windows follow Windows conventions for types and sizes, and some use Linux conventions.
To improve compatibility between different versions and flavors of gcc compilers, we could use the queried system defines from the compiler to correct types and sizes.
The text was updated successfully, but these errors were encountered: