pointfreeco / swift-composable-architecture

A library for building applications in a consistent and understandable way, with composition, testing, and ergonomics in mind.
https://www.pointfree.co/collections/composable-architecture
MIT License
12.35k stars 1.44k forks source link

Swift compiler crash in swift-composable-architecture 0.55.0 #2245

Closed jslew closed 1 year ago

jslew commented 1 year ago

Description

Just upgraded to 0.55.0 due to issue #2244 and now getting an error building my app. I don't think this is a TCA bug per-se, because the swift compiler seems to be crashing, however I'm wondering if other people are getting it. On Xcode 14.2 at the moment and can't upgrade yet for unrelated reasons.

Checklist

Expected behavior

Project should compile

Actual behavior

Compiler crashes

Steps to reproduce

No response

The Composable Architecture version information

0.55.0

Destination operating system

n/a

Xcode version information

14.2

Swift Compiler version information

Stack dump:
0.  Program arguments: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift-frontend -frontend -c /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Dependencies/Dismiss.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Dependencies/IsPresented.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effect.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Animation.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Cancellation.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Publisher.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Publisher/Debouncing.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Publisher/Deferring.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Publisher/Throttling.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/Publisher/Timer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Effects/TaskResult.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/AreOrderedSetsDuplicates.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Binding+IsPresent.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Box.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Create.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/CurrentValueRelay.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Debug.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Deprecations.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/EphemeralState.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Exports.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/Locking.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/NavigationID.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/OpenExistential.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/PresentationID.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/ReturningLastNonNilValue.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/RuntimeWarnings.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/StackIDGenerator.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/TaskCancellableValue.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Internal/TypeName.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/AnyReducer/AnyReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/AnyReducer/AnyReducerBinding.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/AnyReducer/AnyReducerCompatibility.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/AnyReducer/AnyReducerDebug.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/AnyReducer/AnyReducerSignpost.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/ReducerBuilder.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/BindingReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/CombineReducers.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/DebugReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/DependencyKeyWritingReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/EmptyReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/ForEachReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/IfCaseLetReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/IfLetReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/OnChange.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/Optional.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/PresentationReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/Reduce.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/Scope.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/SignpostReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Reducer/Reducers/StackReducer.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/ReducerProtocol.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/Store.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/Alert.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/Binding.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/ConfirmationDialog.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/ForEachStore.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/FullScreenCover.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/IfLetStore.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/NavigationDestination.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/NavigationLinkStore.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/NavigationStackStore.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/Popover.swift -primary-file /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/PresentationModifier.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/Sheet.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/SwitchStore.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/SwiftUI/WithViewStore.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/TestStore.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/UIKit/AlertStateUIKit.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/UIKit/IfLetUIKit.swift /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture/Sources/ComposableArchitecture/ViewStore.swift -supplementary-output-file-map /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/supplementaryOutputs-89 -target arm64-apple-ios14.0-simulator -Xllvm -aarch64-use-tbi -enable-objc-interop -sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator16.2.sdk -I /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Products/Dev-Debug-iphonesimulator -F /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Products/Dev-Debug-iphonesimulator -F /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks -no-color-diagnostics -suppress-warnings -enable-library-evolution -enable-testing -g -module-cache-path /Users/jlew/Library/Developer/Xcode/DerivedData/ModuleCache.noindex -profile-generate -profile-coverage-mapping -swift-version 5 -enforce-exclusivity=checked -Onone -D DEBUG -D SWIFT_PACKAGE -serialize-debugging-options -enable-bare-slash-regex -Xcc -working-directory -Xcc /Volumes/extssd/proj/dk-ios/TuistWorkspace/Tuist/Dependencies/SwiftPackageManager/.build/checkouts/swift-composable-architecture -resource-dir /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift -enable-anonymous-context-mangled-names -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/swift-overrides.hmap -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Products/Dev-Debug-iphonesimulator/include -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/UninstalledProducts/include -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/DerivedSources-normal/arm64 -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/DerivedSources/arm64 -Xcc -I/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/DerivedSources -Xcc -DDEBUG=1 -Xcc -DSWIFT_PACKAGE=1 -module-name ComposableArchitecture -frontend-parseable-output -disable-clang-spi -target-sdk-version 16.2 -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/FullScreenCover.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/IfLetStore.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationDestination.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationLinkStore.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationStackStore.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/Popover.o -o /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/PresentationModifier.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/FullScreenCover.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/IfLetStore.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationDestination.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationLinkStore.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationStackStore.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/Popover.o -index-unit-output-path /swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/PresentationModifier.o -index-store-path /Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Index.noindex/DataStore -index-system-modules
1.  Apple Swift version 5.7.2 (swiftlang-5.7.2.135.5 clang-1400.0.29.51)
2.  Compiling with the current language version
3.  Running pass 'Function Pass Manager' on module '/Users/jlew/Library/Developer/Xcode/DerivedData/DKTuistApps-edxhcjufhupdizfxegkyhbtwqnvw/Build/Intermediates.noindex/swift-composable-architecture.build/Dev-Debug-iphonesimulator/ComposableArchitecture.build/Objects-normal/arm64/NavigationStackStore.o'.
4.  Running pass 'AArch64 Instruction Selection' on function '@"$s22ComposableArchitecture10StackStateV4path33_E04988F2910E2B9A730B0271B047AEFCLLAC8PathViewAELLVyx_GvM"'
Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
0  swift-frontend           0x00000001051c35b0 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) + 56
1  swift-frontend           0x00000001051c25b4 llvm::sys::RunSignalHandlers() + 112
2  swift-frontend           0x00000001051c3c34 SignalHandler(int) + 344
3  libsystem_platform.dylib 0x000000019aaec2a4 _sigtramp + 56
4  libsystem_pthread.dylib  0x000000019aabdcec pthread_kill + 288
5  libsystem_c.dylib        0x000000019a9f62c8 abort + 180
6  swift-frontend           0x0000000100817b70 PrettyStackTraceFrontend::~PrettyStackTraceFrontend() + 0
7  swift-frontend           0x00000001051224c8 llvm::report_fatal_error(llvm::Twine const&, bool) + 280
8  swift-frontend           0x000000010270b6c4 llvm::SelectionDAGISel::CannotYetSelect(llvm::SDNode*) + 1040
9  swift-frontend           0x000000010270ae24 llvm::SelectionDAGISel::SelectCodeCommon(llvm::SDNode*, unsigned char const*, unsigned int) + 15204
10 swift-frontend           0x00000001023322e8 (anonymous namespace)::AArch64DAGToDAGISel::Select(llvm::SDNode*) + 31780
11 swift-frontend           0x0000000102705bb4 llvm::SelectionDAGISel::CodeGenAndEmitDAG() + 2852
12 swift-frontend           0x00000001027037f8 llvm::SelectionDAGISel::SelectAllBasicBlocks(llvm::Function const&) + 8928
13 swift-frontend           0x0000000102700588 llvm::SelectionDAGISel::runOnMachineFunction(llvm::MachineFunction&) + 3212
14 swift-frontend           0x0000000102d7d058 llvm::MachineFunctionPass::runOnFunction(llvm::Function&) + 308
15 swift-frontend           0x0000000104f27744 llvm::FPPassManager::runOnFunction(llvm::Function&) + 1292
16 swift-frontend           0x0000000104f2dc50 llvm::FPPassManager::runOnModule(llvm::Module&) + 60
17 swift-frontend           0x0000000104f27ec8 llvm::legacy::PassManagerImpl::run(llvm::Module&) + 1088
18 swift-frontend           0x0000000100bded50 swift::performLLVM(swift::IRGenOptions const&, swift::DiagnosticEngine&, llvm::sys::SmartMutex<false>*, llvm::GlobalVariable*, llvm::Module*, llvm::TargetMachine*, llvm::StringRef, swift::UnifiedStatsReporter*) + 3392
19 swift-frontend           0x000000010080f000 performCompileStepsPostSILGen(swift::CompilerInstance&, std::__1::unique_ptr<swift::SILModule, std::__1::default_delete<swift::SILModule> >, llvm::PointerUnion<swift::ModuleDecl*, swift::SourceFile*>, swift::PrimarySpecificPaths const&, int&, swift::FrontendObserver*) + 3676
20 swift-frontend           0x00000001008107a0 swift::performFrontend(llvm::ArrayRef<char const*>, char const*, void*, swift::FrontendObserver*) + 5932
21 swift-frontend           0x00000001007b1294 swift::mainEntry(int, char const**) + 3940
22 dyld                     0x000000019a793e50 start + 2544
Command SwiftCompile failed with a nonzero exit code
mbrandonw commented 1 year ago

Hi @jslew, sorry to hear. I haven't see this unfortunately. Are you able to reproduce in a simple project so that we can see the problem?

And have you tried cleaning the project to see if that fixes it?

jslew commented 1 year ago

Trying to repro in a test app, so far no luck reproducing in that scenario. For reasons too complicated to get into, we are integrating TCA and dependencies as dynamic frameworks (using tuist) so looking into whether that might be triggering anything bad.

On Thu, Jun 29, 2023 at 2:45 PM Brandon Williams @.***> wrote:

Hi @jslew https://github.com/jslew, sorry to hear. I haven't see this unfortunately. Are you able to reproduce in a simple project so that we can see the problem?

And have you tried cleaning the project to see if that fixes it?

— Reply to this email directly, view it on GitHub https://github.com/pointfreeco/swift-composable-architecture/issues/2245#issuecomment-1613627894, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC3T5WGNE3IR3QHW5W3TGCLXNXEN7ANCNFSM6AAAAAAZY3TJL4 . You are receiving this because you were mentioned.Message ID: @.*** com>

jslew commented 1 year ago

And yeah definitely tried cleaning, derived data, and all those usual suspects. the swiftc crash is happening to someone else on my team too, identically. I will see if I can switch to Xcode 14.3 (which we can probably use to build this but not our main app unfortunately) and see if there's any change there.

On Thu, Jun 29, 2023 at 2:45 PM Brandon Williams @.***> wrote:

Hi @jslew https://github.com/jslew, sorry to hear. I haven't see this unfortunately. Are you able to reproduce in a simple project so that we can see the problem?

And have you tried cleaning the project to see if that fixes it?

— Reply to this email directly, view it on GitHub https://github.com/pointfreeco/swift-composable-architecture/issues/2245#issuecomment-1613627894, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC3T5WGNE3IR3QHW5W3TGCLXNXEN7ANCNFSM6AAAAAAZY3TJL4 . You are receiving this because you were mentioned.Message ID: @.*** com>

jslew commented 1 year ago

Hey @mbrandonw, I've isolated the problem to these few lines of code from NavigationStackStore.swift:

fileprivate var path: PathView {
    _read { yield PathView(base: self) }
    _modify {
      var path = PathView(base: self)
      yield &path
      self = path.base
    }
    set { self = newValue.base }
  }

If I change the _read/_modify parts to a typical get { PathView(base:self) }, the compiler crash disappears. I have never used that construct myself, so I don't know if it would be possible/reasonable to try changing this in some way (I'm assuming a straight get is not correct).

jslew commented 1 year ago

image Figured it out. Disabling incremental compilation for the package within my target sorts it out (who knows why). But I'll take it, and def. not your problem. Thanks!

mbrandonw commented 1 year ago

That is still very strange though. And this did not happen in 0.54.0 of the library?

The lines with the _read and _modify were there in 0.54.0, so strange that it would start acting up now.

jslew commented 1 year ago

We skipped from 0.53.2 -> 0.55.0 so I haven't tried 54. I would guess that it happens there too.

jslew commented 1 year ago

SwiftCompile normal arm64 Compiling\ NavigationStackStore.swift,\ Popover.swift,\ PresentationModifier.swift,\ Sheet.swift,\ SwitchStore.swift

These files all crop up with the same problem under incremental compiler in Xcode 14.2. Same solution works, Xcode 14.3 doesn't seem to have this issue, so probably not worth digging into much more.

stephencelis commented 1 year ago

Since _read and _modify are optimizations that haven't been made official yet, and because we've seen they can lead to compiler crashes like the one you're seeing, we could maybe consider using get and set instead.