This is an archive of the discontinued LLVM Phabricator instance.

Add option to disable __deallocate #warning
ClosedPublic

Authored by kastiglione on Jul 7 2016, 12:50 PM.

Details

Summary

From r229162:

Visual Studio's SAL extension uses a macro named __deallocate. This
macro is used pervasively

Using -Werror when building for Windows can force the use of -Wno-#warnings
specifically because of this __deallocate #warning. Instead of forcing
builds to disable all #warnings, this option allows libc++ to be built
without this particular warning, while leaving other #warnings enabled.

Diff Detail

Event Timeline

kastiglione retitled this revision from to Add option to disable __deallocate #warning.
kastiglione updated this object.
kastiglione added reviewers: EricWF, compnerd.
compnerd requested changes to this revision.Jul 7 2016, 5:40 PM
compnerd edited edge metadata.

There is another header, __undef_min_max, please apply the same behavior there. This patch, as is, only does it partially, which I don't think is ideal.

include/__undef___deallocate
16

I don't think that we should do this partially. Id rather have the behavior be identical across MSVC and not-MSVC. Please move this above the _MSC_VER check.

This revision now requires changes to proceed.Jul 7 2016, 5:40 PM
kastiglione updated this revision to Diff 63306.Jul 8 2016, 1:30 PM
kastiglione edited edge metadata.

Handle min/max; Cover MSVC too

kastiglione marked an inline comment as done.Jul 8 2016, 1:31 PM
compnerd edited edge metadata.Jul 11 2016, 12:50 PM
compnerd added a reviewer: mclow.lists.
compnerd added a subscriber: llvm-commits.
compnerd accepted this revision.Jul 12 2016, 7:30 AM
compnerd edited edge metadata.
This revision is now accepted and ready to land.Jul 12 2016, 7:30 AM
compnerd closed this revision.Jul 12 2016, 7:47 AM

SVN r275172.