Skip to content

Commit 2db12fe

Browse files
j-piaseckimeta-codesync[bot]
authored andcommitted
Cover jsinspector-modern with Stable API guards (#58309)
Summary: Pull Request resolved: #58309 Classifies `jsinspector-modern:jsinspector` as a "for frameworks" target under the three-tier C++ stable API visibility model. Consumers that opt into `RN_STRICT_API` now get a warning if they include its headers directly, which they can acknowledge with `RN_ALLOW_FRAMEWORKS`; without that flag the guards are inert, so no existing build changes behaviour. Changelog: [Internal] Reviewed By: cipolleschi Differential Revision: D118629799
1 parent 8cfde6d commit 2db12fe

40 files changed

Lines changed: 78 additions & 0 deletions

packages/react-native/ReactCommon/jsinspector-modern/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ target_link_libraries(jsinspector
2323
glog
2424
jsinspector_network
2525
jsinspector_tracing
26+
react_cxxstableapi
2627
react_featureflags
2728
runtimeexecutor
2829
reactperflogger

packages/react-native/ReactCommon/jsinspector-modern/ConsoleMessage.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include "StackTrace.h"
1113

1214
#include <vector>

packages/react-native/ReactCommon/jsinspector-modern/ConsoleTask.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <memory>
1113

1214
namespace facebook::react::jsinspector_modern {

packages/react-native/ReactCommon/jsinspector-modern/ConsoleTaskContext.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include "StackTrace.h"
1113

1214
#include <folly/dynamic.h>

packages/react-native/ReactCommon/jsinspector-modern/ConsoleTaskOrchestrator.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <memory>
1113
#include <mutex>
1214
#include <stack>

packages/react-native/ReactCommon/jsinspector-modern/EmulationAgent.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include "HostTarget.h"
1113
#include "InspectorInterfaces.h"
1214

packages/react-native/ReactCommon/jsinspector-modern/EnumArray.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <array>
1113
#include <limits>
1214

packages/react-native/ReactCommon/jsinspector-modern/ExecutionContext.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include "UniqueMonostate.h"
1113

1214
#include <optional>

packages/react-native/ReactCommon/jsinspector-modern/ExecutionContextManager.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <cinttypes>
1113

1214
namespace facebook::react::jsinspector_modern {

packages/react-native/ReactCommon/jsinspector-modern/FallbackRuntimeAgentDelegate.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include "SessionState.h"
1113

1214
#include <jsinspector-modern/InspectorInterfaces.h>

0 commit comments

Comments
 (0)