diff options
author | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-09-14 04:27:38 +0000 |
---|---|---|
committer | Michael J. Spencer <bigcheesegs@gmail.com> | 2010-09-14 04:27:38 +0000 |
commit | 08047f616977f204df6054c481601f2237cc308d (patch) | |
tree | 8c0b9b43fd57f0ab3390fbcaca1b4b90267e071d /utils | |
parent | bcf4b830b934b01b32e990c0a194db47ab1a36bb (diff) | |
download | llvm-08047f616977f204df6054c481601f2237cc308d.tar.gz llvm-08047f616977f204df6054c481601f2237cc308d.tar.bz2 llvm-08047f616977f204df6054c481601f2237cc308d.tar.xz |
CBackend: Fix MSVC build.
This may produce warnings on MSVS, but it's better than failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113834 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r-- | utils/TableGen/IntrinsicEmitter.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/utils/TableGen/IntrinsicEmitter.cpp b/utils/TableGen/IntrinsicEmitter.cpp index abd221d194..c2aabf7116 100644 --- a/utils/TableGen/IntrinsicEmitter.cpp +++ b/utils/TableGen/IntrinsicEmitter.cpp @@ -69,15 +69,15 @@ void IntrinsicEmitter::run(raw_ostream &OS) { void IntrinsicEmitter::EmitPrefix(raw_ostream &OS) { OS << "// VisualStudio defines setjmp as _setjmp\n" "#if defined(_MSC_VER) && defined(setjmp)\n" - "#define setjmp_undefined_for_visual_studio\n" - "#undef setjmp\n" + "# pragma push_macro(\"setjmp\")\n" + "# undef setjmp\n" "#endif\n\n"; } void IntrinsicEmitter::EmitSuffix(raw_ostream &OS) { - OS << "#if defined(_MSC_VER) && defined(setjmp_undefined_for_visual_studio)\n" + OS << "#if defined(_MSC_VER)\n" "// let's return it to _setjmp state\n" - "#define setjmp _setjmp\n" + "# pragma pop_macro(\"setjmp\")\n" "#endif\n\n"; } |