Open tjzel opened 1 month ago
So there is in fact only one TurboModule.h
file in the filesystem?
When you perform go-to-definition on <ReactCommon/TurboModule.h>
vs. <ReactCommon/ReactCommon/TurboModule.h>
, does clangd open the same file (full path)?
Is the definition of JSI_EXPORT
in a greyed out preprocessor branch (indicating clangd believes it to be an inactive branch) in either case?
With #include <ReactCommon/ReactCommon/TurboModule.h>
:
JSI_EXPORT
isn't greyed.With #include <ReactCommon/TurboModule.h>
:
JSI_EXPORT
is greyed out.I checked for headers with the same name and you are indeed correct. However, they both link to the same header file.
$ find . -iname TurboModule.h
./node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModule.h
./apps/paper-example/ios/Pods/Headers/Public/ReactCommon/ReactCommon/TurboModule.h
./apps/paper-example/ios/Pods/Headers/Private/ReactCommon/ReactCommon/TurboModule.h
$ ls -l apps/paper-example/ios/Pods/Headers/Public/ReactCommon/ReactCommon | grep TurboModule.h
lrwxr-xr-x@ 1 bigpoppe staff 111 Sep 25 07:58 TurboModule.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModule.h
$ ls -l apps/paper-example/ios/Pods/Headers/Private/ReactCommon/ReactCommon | grep TurboModule.h
lrwxr-xr-x@ 1 bigpoppe staff 111 Sep 25 07:58 TurboModule.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModule.h
After further investigation it turns out that when I use ReactCommon/ReactCommon/TurboModule.h
it resolves to the Private
directory. Therefore, that #include
is incorrect in this context, since in this file I should use the Public
header.
When I hovered over the problematic include it turns out it fails because the module fails to compile:
However, the working include also yields similar result, but there's no error squiggle in the editor:
I ran clangd
on the file in isolation with --check -j=1 --log=verbose
and compared the differences in output when I use <ReactCommon/TurboModule.h>
(Public) and <ReactCommon/ReactCommon/TurboModule.h>
(Private). Turns out there's no difference at the compilation point, as far as I can tell. I changed timestamps for easier diff.
outputPublic.log outputPrivate.log
Identifier JSI_EXPORT
is defined in <jsi/jsi.h>
(also duped for Private and Public). When I include this header in the file, JSI_EXPORT
is not greyed out, but failed to build a module
persists.
I really don't understand why failing to compile a module is ok in one case and forwards all defines, and in other it's not.
Maybe part of the issue is that clangd's support for modules is known to be incomplete (https://github.com/clangd/clangd/issues/1293)
Maybe, but it fails to compile the module for both includes.
Anyway, it seems as this issue should be moved to clangd
instead.
I have the following file
NativeWorkletsModuleSpec.h
:NativeWorkletsModuleSpec.h
```cpp #pragma once #includeWhen compiling with XCode and generating
compile_commands.json
with it, the auto-suggestion work for#include <ReactCommon/
, where it suggests<ReactCommon/TurboModule.h>
. However, it seems that for compilation purposes it doesn't work, as theJSI_EXPORT
symbol isn't defined (it's defined inTurboModule.h
).Here's how the relevant part of the header tree:
Tree
```tree . ├── React-callinvoker │ └── ReactCommon │ ├── CallInvoker.h -> ../../../../../../../../node_modules/react-native/ReactCommon/callinvoker/ReactCommon/CallInvoker.h │ └── SchedulerPriority.h -> ../../../../../../../../node_modules/react-native/ReactCommon/callinvoker/ReactCommon/SchedulerPriority.h ├── ReactCommon │ ├── ReactCommon │ │ ├── CallbackWrapper.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/CallbackWrapper.h │ │ ├── CxxTurboModuleUtils.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/CxxTurboModuleUtils.h │ │ ├── LongLivedObject.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/LongLivedObject.h │ │ ├── TurboCxxModule.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboCxxModule.h │ │ ├── TurboModule.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModule.h │ │ ├── TurboModuleBinding.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModuleBinding.h │ │ ├── TurboModulePerfLogger.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModulePerfLogger.h │ │ └── TurboModuleUtils.h -> ../../../../../../../../node_modules/react-native/ReactCommon/react/nativemodule/core/ReactCommon/TurboModuleUtils.h │ ├── ReactCommon-umbrella.h -> ../../../Target Support Files/ReactCommon/ReactCommon-umbrella.h │ ├── ReactCommon.modulemap -> ../../../Target Support Files/ReactCommon/ReactCommon.modulemap │ └── react │ └── bridging │ ├── AString.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/AString.h │ ├── Array.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Array.h │ ├── Base.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Base.h │ ├── Bool.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Bool.h │ ├── Bridging.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Bridging.h │ ├── CallbackWrapper.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/CallbackWrapper.h │ ├── Class.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Class.h │ ├── Convert.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Convert.h │ ├── Dynamic.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Dynamic.h │ ├── Error.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Error.h │ ├── EventEmitter.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/EventEmitter.h │ ├── Function.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Function.h │ ├── LongLivedObject.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/LongLivedObject.h │ ├── Number.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Number.h │ ├── Object.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Object.h │ ├── Promise.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Promise.h │ └── Value.h -> ../../../../../../../../../node_modules/react-native/ReactCommon/react/bridging/Value.h ```Everything seems to be linked correctly, here's the log for compilation command for
ReactNativeModuleSpec.cpp
, which is in the same directory as its header file:Clangd compile command log
```text I[15:37:55.884] <-- textDocument/documentSymbol(95) I[15:37:55.907] ASTWorker building file /Users/bigpoppe/swmansion/reanimated/primary/packages/react-native-reanimated/Common/cpp/worklets/NativeModules/NativeWorkletsModuleSpec.h version 87 with command inferred from /Users/bigpoppe/swmansion/reanimated/primary/packages/react-native-reanimated/Common/cpp/reanimated/NativeModules/NativeReanimatedModule.cpp [/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods] /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -fno-color-diagnostics -fmodules-prune-interval=86400 -fmodules-prune-after=345600 -fbuild-session-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/DerivedData/ModuleCache.noindex/Session.modulevalidation -fmodules-validate-once-per-build-session -Wnon-modular-include-in-framework-module -Werror=non-modular-include-in-framework-module -Wno-trigraphs -Wno-missing-field-initializers -Wno-missing-prototypes -Werror=return-type -Wdocumentation -Wunreachable-code -Werror=deprecated-objc-isa-usage -Werror=objc-root-class -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-float-conversion -Wnon-literal-null-conversion -Wobjc-literal-conversion -Wshorten-64-to-32 -Wno-newline-eof -Wno-c++11-extensions -Wno-implicit-fallthrough -fstrict-aliasing -Wdeprecated-declarations -Winvalid-offsetof -Wno-sign-conversion -Winfinite-recursion -Wmove -Wcomma -Wblock-capture-autoreleasing -Wstrict-prototypes -Wrange-loop-analysis -Wno-semicolon-before-method-body -Wunguarded-availability -Wno-comma -Wno-shorten-64-to-32 -Wno-comma -Wno-shorten-64-to-32 --target=arm64-apple-ios13.4-simulator -stdlib=libc++ -fmodules -fmodules-cache-path=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/DerivedData/ModuleCache.noindex -fmodule-name=RNReanimated -D _LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_DEBUG -fpascal-strings -O0 -fno-common -D POD_CONFIGURATION_DEBUG=1 -D DEBUG=1 -D COCOAPODS=1 -D HERMES_ENABLE_DEBUGGER=1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.0.sdk -g -iquote /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-generated-files.hmap -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-own-target-headers.hmap -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-all-non-framework-target-headers.hmap -ivfsoverlay /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Pods-8699adb1dd336b26511df848a716bd42-VFS-iphonesimulator/all-product-headers.yaml -iquote /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-project-headers.hmap -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/RNReanimated/include -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/RNReanimated -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/DoubleConversion -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/FBLazyVector -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTRequired -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTTypeSafety -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-Core -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-Fabric -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-FabricComponents -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-FabricImage -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-ImageManager -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-NativeModulesApple -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-RCTFabric -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-RCTText -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-callinvoker -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-cxxreact -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-debug -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-featureflags -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-graphics -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-hermes -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsi -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsiexecutor -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsinspector -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-logger -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-nativeconfig -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-perflogger -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-performancetimeline -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-rendererconsistency -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-rendererdebug -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-runtimeexecutor -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-runtimescheduler -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-utils -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCodegen -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/fmt -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/glog -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/hermes-engine -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost-for-react-native -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/glog -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-hermes -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/hermes-engine -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native-reanimated/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native-reanimated -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost-for-react-native -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/DoubleConversion -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/React-Core -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources-normal/arm64 -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources/arm64 -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/RNReanimated -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/hermes-engine/destroot/Library/Frameworks/universal -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/XCFrameworkIntermediates/hermes-engine/Pre-built -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/React-hermes -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/DoubleConversion/DoubleConversion.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTDeprecation/RCTDeprecation.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTFabric/React-RCTFabric.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTTypeSafety/RCTTypeSafety.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React/React-Core.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCodegen/ReactCodegen.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCommon/ReactCommon.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_Fabric/React-Fabric.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_FabricComponents/React-FabricComponents.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_NativeModulesApple/React-NativeModulesApple.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/folly/RCT-Folly.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/glog/glog.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/jsi/React-jsi.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/jsinspector_modern/React-jsinspector.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_debug/React-debug.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_featureflags/React-featureflags.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_debug/React-rendererdebug.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_graphics/React-graphics.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_imagemanager/React-ImageManager.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_utils/React-utils.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/yoga/Yoga.modulemap -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D REACT_NATIVE_MINOR_VERSION=75 -D IS_REANIMATED_EXAMPLE_APP -D REANIMATED_VERSION=3.15.0 -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D FOLLY_CFG_NO_COROUTINES=1 -D FOLLY_HAVE_CLOCK_GETTIME=1 -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32 -D REACT_NATIVE_MINOR_VERSION=75 -Wno-comma -Wno-shorten-64-to-32 -Wno-documentation -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D FOLLY_CFG_NO_COROUTINES=1 -D FOLLY_HAVE_CLOCK_GETTIME=1 -Wno-comma -Wno-shorten-64-to-32 -include "/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Target Support Files/RNReanimated/RNReanimated-prefix.pch" --serialize-diagnostics /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/Objects-normal/arm64/NativeReanimatedModule.dia -c -Wno-reorder-init-list -Wno-implicit-int-float-conversion -Wno-c99-designator -Wno-final-dtor-non-final-class -Wno-extra-semi-stmt -Wno-misleading-indentation -Wno-quoted-include-in-framework-header -Wno-implicit-fallthrough -Wno-enum-enum-conversion -Wno-enum-float-conversion -Wno-elaborated-enum-base -Wno-reserved-identifier -Wno-gnu-folding-constant -mlinker-version=1115.7.3 --target=arm64-apple-ios13.4.0-simulator -resource-dir=/opt/homebrew/Cellar/llvm/18.1.8/lib/clang/18 -x c++-header -std=c++20 -- /Users/bigpoppe/swmansion/reanimated/primary/packages/react-native-reanimated/Common/cpp/worklets/NativeModules/NativeWorkletsModuleSpec.h V[15:37:55.908] Driver produced command: cc1 -cc1 -triple arm64-apple-ios13.4.0-simulator -Wundef-prefix=TARGET_OS_ -Werror=undef-prefix -Wdeprecated-objc-isa-usage -Werror=deprecated-objc-isa-usage -Werror=implicit-function-declaration -fsyntax-only -disable-free -clear-ast-before-backend -disable-llvm-verifier -discard-value-names -main-file-name NativeWorkletsModuleSpec.h -mrelocation-model pic -pic-level 2 -mframe-pointer=non-leaf -ffp-contract=on -fno-rounding-math -funwind-tables=1 -target-sdk-version=18.0 -fcompatibility-qualified-id-block-type-checking -fvisibility-inlines-hidden-static-local-var -fbuiltin-headers-in-system-modules -fdefine-target-os-macros -target-cpu apple-m1 -target-feature +zcm -target-feature +zcz -target-feature +v8.5a -target-feature +aes -target-feature +crc -target-feature +dotprod -target-feature +complxnum -target-feature +fp-armv8 -target-feature +fullfp16 -target-feature +fp16fml -target-feature +jsconv -target-feature +lse -target-feature +pauth -target-feature +ras -target-feature +rcpc -target-feature +rdm -target-feature +sha2 -target-feature +sha3 -target-feature +neon -target-abi darwinpcs -debug-info-kind=standalone -dwarf-version=4 -debugger-tuning=lldb -fdebug-compilation-dir=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods -target-linker-version 1115.7.3 -fcoverage-compilation-dir=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods -resource-dir /opt/homebrew/Cellar/llvm/18.1.8/lib/clang/18 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.0.sdk -iquote /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-generated-files.hmap -ivfsoverlay /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Pods-8699adb1dd336b26511df848a716bd42-VFS-iphonesimulator/all-product-headers.yaml -iquote /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-project-headers.hmap -include "/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Target Support Files/RNReanimated/RNReanimated-prefix.pch" -D _LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_DEBUG -D POD_CONFIGURATION_DEBUG=1 -D DEBUG=1 -D COCOAPODS=1 -D HERMES_ENABLE_DEBUGGER=1 -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-own-target-headers.hmap -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/RNReanimated-all-non-framework-target-headers.hmap -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/RNReanimated/include -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/RNReanimated -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/DoubleConversion -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/FBLazyVector -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTRequired -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTTypeSafety -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-Core -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-Fabric -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-FabricComponents -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-FabricImage -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-ImageManager -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-NativeModulesApple -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-RCTFabric -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-RCTText -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-callinvoker -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-cxxreact -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-debug -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-featureflags -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-graphics -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-hermes -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsi -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsiexecutor -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-jsinspector -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-logger -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-nativeconfig -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-perflogger -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-performancetimeline -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-rendererconsistency -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-rendererdebug -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-runtimeexecutor -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-runtimescheduler -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-utils -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCodegen -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/fmt -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/glog -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/hermes-engine -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost-for-react-native -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/glog -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React-hermes -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/hermes-engine -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native-reanimated/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/ReactCommon -I /Users/bigpoppe/swmansion/reanimated/primary/node_modules/react-native-reanimated -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/RCT-Folly -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost-for-react-native -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/DoubleConversion -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/React-Core -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/boost -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Private/Yoga -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources-normal/arm64 -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources/arm64 -I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/DerivedSources -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/RNReanimated -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/hermes-engine/destroot/Library/Frameworks/universal -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/XCFrameworkIntermediates/hermes-engine/Pre-built -F/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Products/Debug-iphonesimulator/React-hermes -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D REACT_NATIVE_MINOR_VERSION=75 -D IS_REANIMATED_EXAMPLE_APP -D REANIMATED_VERSION=3.15.0 -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D FOLLY_CFG_NO_COROUTINES=1 -D FOLLY_HAVE_CLOCK_GETTIME=1 -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D REACT_NATIVE_MINOR_VERSION=75 -D FOLLY_NO_CONFIG -D FOLLY_MOBILE=1 -D FOLLY_USE_LIBCPP=1 -D FOLLY_CFG_NO_COROUTINES=1 -D FOLLY_HAVE_CLOCK_GETTIME=1 -stdlib=libc++ -internal-isystem /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.0.sdk/usr/include/c++/v1 -internal-isystem /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.0.sdk/usr/local/include -internal-isystem /opt/homebrew/Cellar/llvm/18.1.8/lib/clang/18/include -internal-externc-isystem /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.0.sdk/usr/include -O0 -Wnon-modular-include-in-framework-module -Werror=non-modular-include-in-framework-module -Wno-trigraphs -Wno-missing-field-initializers -Wno-missing-prototypes -Werror=return-type -Wdocumentation -Wunreachable-code -Werror=deprecated-objc-isa-usage -Werror=objc-root-class -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors -Wno-missing-braces -Wparentheses -Wswitch -Wunused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wempty-body -Wuninitialized -Wconditional-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wbool-conversion -Wenum-conversion -Wno-float-conversion -Wnon-literal-null-conversion -Wobjc-literal-conversion -Wshorten-64-to-32 -Wno-newline-eof -Wno-c++11-extensions -Wno-implicit-fallthrough -Wdeprecated-declarations -Winvalid-offsetof -Wno-sign-conversion -Winfinite-recursion -Wmove -Wcomma -Wblock-capture-autoreleasing -Wstrict-prototypes -Wrange-loop-analysis -Wno-semicolon-before-method-body -Wunguarded-availability -Wno-comma -Wno-shorten-64-to-32 -Wno-comma -Wno-shorten-64-to-32 -Wno-comma -Wno-shorten-64-to-32 -Wno-comma -Wno-shorten-64-to-32 -Wno-documentation -Wno-comma -Wno-shorten-64-to-32 -Wno-reorder-init-list -Wno-implicit-int-float-conversion -Wno-c99-designator -Wno-final-dtor-non-final-class -Wno-extra-semi-stmt -Wno-misleading-indentation -Wno-quoted-include-in-framework-header -Wno-implicit-fallthrough -Wno-enum-enum-conversion -Wno-enum-float-conversion -Wno-elaborated-enum-base -Wno-reserved-identifier -Wno-gnu-folding-constant -std=c++20 -fdeprecated-macro -ferror-limit 19 -fmacro-backtrace-limit=0 -stack-protector 1 -fblocks -fencode-extended-block-signature -fregister-global-dtors-with-atexit -fgnuc-version=4.2.1 -fmodules -fimplicit-module-maps -fmodules-cache-path=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/DerivedData/ModuleCache.noindex -fmodule-name=RNReanimated -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/DoubleConversion/DoubleConversion.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTDeprecation/RCTDeprecation.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTFabric/React-RCTFabric.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/RCTTypeSafety/RCTTypeSafety.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React/React-Core.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCodegen/ReactCodegen.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCommon/ReactCommon.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_Fabric/React-Fabric.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_FabricComponents/React-FabricComponents.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/React_NativeModulesApple/React-NativeModulesApple.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/folly/RCT-Folly.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/glog/glog.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/jsi/React-jsi.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/jsinspector_modern/React-jsinspector.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_debug/React-debug.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_featureflags/React-featureflags.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_debug/React-rendererdebug.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_graphics/React-graphics.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_renderer_imagemanager/React-ImageManager.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/react_utils/React-utils.modulemap -fmodule-map-file=/Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/yoga/Yoga.modulemap -fmodules-prune-interval=86400 -fmodules-prune-after=345600 -fbuild-session-timestamp=1727098227 -fmodules-validate-once-per-build-session -fmodules-validate-system-headers -fskip-odr-check-in-gmf -fcxx-exceptions -fexceptions -fpascal-strings -fmax-type-align=16 -fdiagnostics-show-note-include-stack -serialize-diagnostic-file /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RNReanimated.build/Objects-normal/arm64/NativeReanimatedModule.dia -no-round-trip-args -D__GCC_HAVE_DWARF2_CFI_ASM=1 -x c++-header /Users/bigpoppe/swmansion/reanimated/primary/packages/react-native-reanimated/Common/cpp/worklets/NativeModules/NativeWorkletsModuleSpec.h ```As you can see,
-I /Users/bigpoppe/swmansion/reanimated/primary/apps/paper-example/ios/Pods/Headers/Public/ReactCommon
is present there.This is the log for the autocompletion:
Autocompletion log
```text I[15:56:44.415] <-- textDocument/completion(457) I[15:56:44.438] Code complete: sema context IncludedFile, query scopes [] (AnyScope=true), expected typeAs you can see, it suggests
TurboModule.h
.Here's the whole log for auto-suggestion and what happens afterwards (when clangd tries to compile): ReactCommon.log
On the other hand, here's the log when I use
<ReactCommon/ReactCommon/TurboModule.h>
instead: ReactCommonReactCommon.logPlease let me know if you want more logs/unverbose logs.
System information Clangd version: Homebrew clangd version 18.1.8 Features: mac+xpc Platform: arm64-apple-darwin24.1.0
clangd extension version: v0.1.29
Operating system: macOS Sequoia 15.1 Beta