|
| 1 | +/* |
| 2 | + * Copyright (c) Meta Platforms, Inc. and affiliates. |
| 3 | + * |
| 4 | + * This source code is licensed under the MIT license found in the |
| 5 | + * LICENSE file in the root directory of this source tree. |
| 6 | + */ |
| 7 | + |
| 8 | +#pragma once |
| 9 | + |
| 10 | +// ============================================================================= |
| 11 | +// Umbrella header for the `react/renderer/debug` module - public entry point. |
| 12 | +// |
| 13 | +// #include <React/RendererDebug.h> |
| 14 | +// |
| 15 | +// Re-exports the module's public interface headers. React Native's own code |
| 16 | +// should keep using the fine-grained `<react/renderer/debug/...>` includes, |
| 17 | +// except in headers it exports to consumers: those are preprocessed in the |
| 18 | +// consumer's translation unit, where the fine-grained include hits this |
| 19 | +// module's <react/cxxstableapi/UmbrellaGuard.h>. `RN_ALLOW_FRAMEWORKS` does not |
| 20 | +// suppress that guard, so a "for frameworks" header must reach this module |
| 21 | +// through the umbrella. |
| 22 | +// ============================================================================= |
| 23 | + |
| 24 | +// Marks that the following headers are pulled in through the umbrella, so their |
| 25 | +// shared guard (<react/cxxstableapi/UmbrellaGuard.h>) accepts them. The marker |
| 26 | +// is saved and restored rather than defined and undefined: the scope ends at |
| 27 | +// this block, so later *direct* includes in the same TU are still caught, and |
| 28 | +// it nests inside an enclosing umbrella rather than disarming it. |
| 29 | +#pragma push_macro("RN_UMBRELLA_CONTEXT") |
| 30 | +#undef RN_UMBRELLA_CONTEXT |
| 31 | +#define RN_UMBRELLA_CONTEXT 1 |
| 32 | + |
| 33 | +#include <react/renderer/debug/DebugStringConvertible.h> |
| 34 | +#include <react/renderer/debug/DebugStringConvertibleItem.h> |
| 35 | +#include <react/renderer/debug/debugStringConvertibleUtils.h> |
| 36 | +#include <react/renderer/debug/flags.h> |
| 37 | + |
| 38 | +#undef RN_UMBRELLA_CONTEXT |
| 39 | +#pragma pop_macro("RN_UMBRELLA_CONTEXT") |
0 commit comments