MongoDB C++ Driver legacy-1.1.2
Loading...
Searching...
No Matches
redef_macros.h
Go to the documentation of this file.
1
6/* Copyright 2009 10gen Inc.
7 *
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20
21// If you define a new global un-prefixed macro, please add it here and in undef_macros
22
23#define MONGO_MACROS_PUSHED 1
24
25#if defined(_WIN32)
26#pragma push_macro("min")
27#undef min
28#pragma push_macro("max")
29#undef max
30#pragma push_macro("NOMINMAX")
31#ifndef NOMINMAX
32#define NOMINMAX
33#endif
34#endif
35
36// bson/inline_decls.h
37#pragma push_macro("NOINLINE_DECL")
38#undef NOINLINE_DECL
39#pragma push_macro("PACKED_DECL")
40#undef PACKED_DECL
41
42// util/assert_util.h
43#pragma push_macro("verify")
44#undef verify
45#define verify(expression) MONGO_verify(expression)
46#pragma push_macro("invariant")
47#undef invariant
48#define invariant MONGO_invariant
49#pragma push_macro("invariantOK")
50#undef invariantOK
51#define invariantOK MONGO_invariantOK
52#pragma push_macro("wassert")
53#undef wassert
54#define wassert MONGO_wassert
55#pragma push_macro("massert")
56#undef massert
57#define massert MONGO_massert
58#pragma push_macro("uassert")
59#undef uassert
60#define uassert MONGO_uassert
61#pragma push_macro("DESTRUCTOR_GUARD")
62#undef DESTRUCTOR_GUARD
63#define DESTRUCTOR_GUARD MONGO_DESTRUCTOR_GUARD