[llvm-bugs] [Bug 33735] Clang cannot parse xstring in Visual Studio 2017
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Jul 11 08:43:18 PDT 2017
https://bugs.llvm.org/show_bug.cgi?id=33735
Reid Kleckner <rnk at google.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rnk at google.com
Resolution|--- |INVALID
Status|NEW |RESOLVED
--- Comment #1 from Reid Kleckner <rnk at google.com> ---
This error suggests you are not using Clang's version of stddef.h, which
provides a constexpr-compatible implementation of offsetof.
This code compiles successfully with clang on Windows:
#include <stddef.h>
struct Foo { int x, y; };
constexpr size_t off = offsetof(Foo, y);
Check your -isystem flags, and make sure the Windows SDK include directory does
not appear on that list, or it will supersede clang's internal resource
directory headers. Use -imsvc for Windows SDK headers and MSVCRT headers to
make them system headers that appear after the resource directory in include
search.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170711/45a5d574/attachment.html>
More information about the llvm-bugs
mailing list