<div dir="ltr">Thanks! I moved the following to a temporary location:<div><div>~</div><div>├── .lldb</div><div>│ ├── lldb-history</div><div>│ ├── lldb-repl-history</div><div>│ └── lldb-swift-history</div><div>└── .lldb-swift-history</div></div><div><br></div><div>And that made the REPL work again.</div><div>I will zip and attach those files to <span style="font-size:12.800000190734863px">28657007.</span></div><div><span style="font-size:12.800000190734863px">/Jens</span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Oct 6, 2016 at 9:52 PM, Jim Ingham <span dir="ltr"><<a href="mailto:jingham@apple.com" target="_blank">jingham@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">There is a known bug in libedit's history file reader that can cause this crash. libedit is a system component that lldb uses to do command-line editing and the like.<br>
<br>
Try moving ~/.lldb-history to some other name, and then rerunning the REPL. If that works, can you attach that history file to the Radar you mentioned, so we can make sure this is the same history reading bug?<br>
<br>
Thanks,<br>
<br>
Jim<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
> On Oct 6, 2016, at 12:46 PM, Jens Persson via swift-users <<a href="mailto:swift-users@swift.org">swift-users@swift.org</a>> wrote:<br>
><br>
> I've filed radar 28657007 and attached the two crashlogs that is generated (one for lldb, and one for repl_swift.<br>
> /Jens<br>
><br>
> On Thu, Oct 6, 2016 at 9:25 PM, Jens Persson <<a href="mailto:jens@bitcycle.com">jens@bitcycle.com</a>> wrote:<br>
> Here is with Xcode.app:<br>
><br>
> › sudo xcode-select -s /Applications/Xcode.app<br>
> Password:<br>
> ›<br>
> › swift -v<br>
> Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38)<br>
> Target: x86_64-apple-macosx10.9<br>
> /Applications/Xcode.app/<wbr>Contents/Developer/usr/bin/<wbr>lldb "--repl=-target x86_64-apple-macosx10.9 -enable-objc-interop -sdk /Applications/Xcode.app/<wbr>Contents/Developer/Platforms/<wbr>MacOSX.platform/Developer/<wbr>SDKs/MacOSX10.12.sdk -color-diagnostics"<br>
> Welcome to Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38). Type :help for assistance.<br>
> Segmentation fault: 11<br>
><br>
> /Jens<br>
><br>
><br>
> On Thu, Oct 6, 2016 at 9:23 PM, Jens Persson <<a href="mailto:jens@bitcycle.com">jens@bitcycle.com</a>> wrote:<br>
> I was trying both Xcode and Xcode-beta, I just happened to copy paste while Xcode-beta was selected ... Anyway, both of them crash like that.<br>
> /Jens<br>
><br>
><br>
> On Thu, Oct 6, 2016 at 7:22 PM, Kate Stone <<a href="mailto:k8stone@apple.com">k8stone@apple.com</a>> wrote:<br>
> If you’ve specified “sudo xcode-select -s /Applications/Xcode.app” then it’s surprising that the REPL session is attempting to use the LLDB and SDK from /Applications/Xcode-beta.app. Can you double-check what “xcode-select -p” reports?<br>
><br>
> I can’t say I’ve seen a segmentation fault on REPL launch. If you see the same behavior once moving to the GM build of Xcode it would definitely be worth filing a radar via <a href="http://bugreport.apple.com" rel="noreferrer" target="_blank">bugreport.apple.com</a> with an LLDB crashlog attached to investigate further.<br>
><br>
> Kate Stone <a href="mailto:k8stone@apple.com">k8stone@apple.com</a><br>
> Xcode Low Level Tools<br>
><br>
>> On Oct 6, 2016, at 6:51 AM, Jens Persson via swift-users <<a href="mailto:swift-users@swift.org">swift-users@swift.org</a>> wrote:<br>
>><br>
>> After updating to Sierra I can no longer use the Swift REPL. It crashes immediately (see Terminal session below). Anyone else having the same problem, any workaround?<br>
>><br>
>> It didn't help to download and reinstall the command line tools for 10.12.<br>
>><br>
>> (I had Xcode 8 and 8.1 beta installed before updating to Sierra. It might have happened just after I did a sudo xcode-select -s /Applications/Xcode.app )<br>
>><br>
>> See Terminal session below.<br>
>><br>
>> /Jens<br>
>><br>
>><br>
>> › swift<br>
>> Welcome to Apple Swift version 3.0 (swiftlang-800.0.48 clang-800.0.40). Type :help for assistance.<br>
>> Segmentation fault: 11<br>
>> ›<br>
>> › swift -v<br>
>> Apple Swift version 3.0 (swiftlang-800.0.49 clang-800.0.40)<br>
>> Target: x86_64-apple-macosx10.9<br>
>> /Applications/Xcode-beta.app/<wbr>Contents/Developer/usr/bin/<wbr>lldb "--repl=-target x86_64-apple-macosx10.9 -enable-objc-interop -sdk /Applications/Xcode-beta.app/<wbr>Contents/Developer/Platforms/<wbr>MacOSX.platform/Developer/<wbr>SDKs/MacOSX10.12.sdk -color-diagnostics"<br>
>> Welcome to Apple Swift version 3.0 (swiftlang-800.0.48 clang-800.0.40). Type :help for assistance.<br>
>> Segmentation fault: 11<br>
>> ›<br>
>> › /Applications/Xcode.app/<wbr>Contents/Developer/Toolchains/<wbr>XcodeDefault.xctoolchain/usr/<wbr>bin/swift -sdk /Applications/Xcode.app/<wbr>Contents/Developer/Platforms/<wbr>MacOSX.platform/Developer/<wbr>SDKs/MacOSX10.12.sdk -target x86_64-apple-macosx10.12<br>
>> Welcome to Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38). Type :help for assistance.<br>
>> Segmentation fault: 11<br>
>><br>
>><br>
>> ______________________________<wbr>_________________<br>
>> swift-users mailing list<br>
>> <a href="mailto:swift-users@swift.org">swift-users@swift.org</a><br>
>> <a href="https://lists.swift.org/mailman/listinfo/swift-users" rel="noreferrer" target="_blank">https://lists.swift.org/<wbr>mailman/listinfo/swift-users</a><br>
><br>
><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> swift-users mailing list<br>
> <a href="mailto:swift-users@swift.org">swift-users@swift.org</a><br>
> <a href="https://lists.swift.org/mailman/listinfo/swift-users" rel="noreferrer" target="_blank">https://lists.swift.org/<wbr>mailman/listinfo/swift-users</a><br>
<br>
</div></div></blockquote></div><br></div>