[PATCH] D29464: [MinGWToolChain] Don't use GCC headers on Win32

Mateusz MikuĊ‚a via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 2 10:55:00 PST 2017


mati865 added a comment.

I don't know about Linux but on Windows this code was causing issue:

  #include <limits.h>
  int main() { char buf[PATH_MAX]; }

Include order:

- Before patch: Clang limits.h (lib\\clang\\3.9.1\\include) -> GCC limits.h (lib\\gcc\\x86_64-w64-mingw32\\6.3.0\\include-fixed) here whole header is skipped due to the guards -> Clang limits.h



- After patch: Clang limits.h (lib\\clang\\3.9.1\\include) -> mingw-w64 limits.h -> Clang limits.h

Before patch mingw-w64 limits.h weren't included so it was big problem.


https://reviews.llvm.org/D29464





More information about the cfe-commits mailing list