Archiving a Swift 2 app fails with "Command failed due to signal: Abort trap: 6"

Originator:benchatelain
Number:rdar://21479429 Date Originated:21-Jun-2015 10:02 PM
Status:Closed Resolved:yes, in Xcode 7b2
Product:Developer Tools Product Version:Xcode7-beta1 (7A120f)
Classification:Crash/Hang/Data Loss Reproducible:Always
 
Summary:
Building a mostly Swift 2 iOS app (with a little bit of Objective-C) works fine when targeting either the simulator or a device. However, attempting to create an archive always fails with “Command failed due to signal: Abort trap: 6”


Steps to Reproduce:
1. Select “iOS Device” in the destination selector
2. Select menu entry: Product > Archive

Expected Results:
Xcode will build successfully and present the Organizer with a new archive listed.

Actual Results:
The following build error is emitted: Command failed due to signal: Abort trap: 6


Notes:


Assertion failed: (D->getSourceRange().isValid()), function buildDeclarationRefinementContext, file /Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-700.0.38.1/src/swift/lib/Sema/TypeChecker.cpp, line 946.
0  swift                    0x000000011135fe0b llvm::sys::PrintStackTrace(__sFILE*) + 43
1  swift                    0x000000011136054b SignalHandler(int) + 379
2  libsystem_platform.dylib 0x00007fff9130df1a _sigtramp + 26
3  libsystem_platform.dylib 000000000000000000 _sigtramp + 1859068160
4  libsystem_c.dylib        0x00007fff8fe94b53 abort + 129
5  libsystem_c.dylib        0x00007fff8fe5cc39 basename + 0
6  swift                    0x000000010f9c4e92 (anonymous namespace)::TypeRefinementContextBuilder::walkToDeclPre(swift::Decl*) + 1058
7  swift                    0x000000010fa93f5d (anonymous namespace)::Traversal::doIt(swift::Decl*) + 157
8  swift                    0x000000010fa98244 (anonymous namespace)::Traversal::visitNominalTypeDecl(swift::NominalTypeDecl*) + 164
9  swift                    0x000000010fa93fb2 (anonymous namespace)::Traversal::doIt(swift::Decl*) + 242
10 swift                    0x000000010fa93eab swift::Decl::walk(swift::ASTWalker&) + 27
11 swift                    0x000000010f9bea19 swift::TypeChecker::buildTypeRefinementContextHierarchy(swift::SourceFile&, unsigned int) + 329
12 swift                    0x000000010f9be50d swift::performTypeChecking(swift::SourceFile&, swift::TopLevelContext&, swift::OptionSet<swift::TypeCheckingFlags, unsigned int>, unsigned int) + 1213
13 swift                    0x000000010f7d1635 swift::CompilerInstance::performSema() + 4341
14 swift                    0x000000010f3775b0 performCompile(swift::CompilerInstance&, swift::CompilerInvocation&, llvm::ArrayRef<char const*>, int&) + 736
15 swift                    0x000000010f3770b3 frontend_main(llvm::ArrayRef<char const*>, char const*, void*) + 2515
16 swift                    0x000000010f37328f main + 1983
17 libdyld.dylib            0x00007fff8a8485c9 start + 1
Stack dump:
0.	Program arguments: /Applications/Xcode7-beta1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -emit-bc /Users/phatblat/dev/ios/Octopad/Octopad/AppDelegate.swift

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!