<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hmm - you’re right. I tried compiling the example code on master, and didn’t see a crash. I just tried again, though, and now I do.<div class=""><br class=""></div><div class="">The stack trace is new to me, but it does look related to the ArchetypeBuilder changes.</div><div class=""><br class=""></div><div class="">- Joe<br class=""><div class=""><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Feb 10, 2016, at 9:29 AM, Joe Groff <<a href="mailto:jgroff@apple.com" class="">jgroff@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">I'm not certain that yesterday's fix would cover this case.<div class=""><br class=""></div><div class="">-Joe</div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Feb 10, 2016, at 9:20 AM, Joe Pamer via swift-dev <<a href="mailto:swift-dev@swift.org" class="">swift-dev@swift.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Alex,<div class=""><br class=""></div><div class="">I’m pretty sure Joe Groff pushed a fix for this yesterday (it landed in swift-2.2-branch with 9e9537 and master as c165811). I’ll double-check.</div><div class=""><br class=""></div><div class="">Thanks!</div><div class="">- Joe</div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Feb 9, 2016, at 11:56 PM, Alex Hoppen via swift-dev <<a href="mailto:swift-dev@swift.org" class="">swift-dev@swift.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi everyone,<div class=""><br class=""></div><div class="">I just found a major regression bug in Swift 2.2 (it’s tracked under <a href="https://bugs.swift.org/browse/SR-706" class="">SR-706</a>). Since Swift 2.2 development seems to come to an end I wanted to raise some attention for this bug by posting it here as well.</div><div class=""><br class=""></div><div class="">- Alex</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div style="margin: 0px; padding: 0px; color: rgb(51, 51, 51); font-family: Arial, sans-serif; font-size: 14px;" class="">When using the generic argument of a function as a parameter of another generic class that is used in the signature, the compiler crashes with <tt style="background-color: rgb(245, 245, 245); border: 1px solid rgb(204, 204, 204); border-top-left-radius: 2px; border-top-right-radius: 2px; border-bottom-right-radius: 2px; border-bottom-left-radius: 2px; padding: 1px 3px; background-position: initial initial; background-repeat: initial initial;" class="">Illegal instruction: 4</tt></div><h2 style="margin: 30px 0px 0px; padding: 0px; color: rgb(51, 51, 51); font-size: 20px; font-weight: normal; line-height: 1.5; font-family: Arial, sans-serif;" class=""><a name="Example" title="Follow link" style="color: rgb(59, 115, 175);" class=""></a>Example</h2><div class="panel code" style="margin: 9px 0px; padding: 0px; border: 1px solid rgb(204, 204, 204); background-color: rgb(245, 245, 245); font-size: 12px; line-height: 1.33333333333333; font-family: monospace; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; color: rgb(51, 51, 51);"><div class="codeContent panelContent" style="margin: 0px; padding: 9px 12px;"><pre class="code-java" style="margin-top: 0px; margin-bottom: 0px; padding: 0px; max-height: 30em; overflow: auto; white-space: pre-wrap; word-wrap: normal;">class GenericClass<T> { }
protocol MyProtocol { }
class MyClass {
func myFunction<T, O: GenericClass<T> where T: MyProtocol>(myArg: O) -> T {
fatalError()
}
}
</pre></div></div><h2 style="margin: 30px 0px 0px; padding: 0px; color: rgb(51, 51, 51); font-size: 20px; font-weight: normal; line-height: 1.5; font-family: Arial, sans-serif;" class=""><a name="Interestingcrashfacts" title="Follow link" style="color: rgb(59, 115, 175);" class=""></a>Interesting crash facts</h2><ul class="alternate" type="square" style="margin: 10px 0px 0px; color: rgb(51, 51, 51); font-family: Arial, sans-serif; font-size: 14px;"><li class="">This used to work with Swift 2.1</li><li class="">This works with the version of Swift that is shipped with Xcode 7.3 beta 2 (7D129n)</li><li class="">It crashes the Swift 2.2 and Swift 3 compiler since the snapshot of 01/11/2016 (that’s the oldest snapshot I have installed)</li><li class="">The code compiles fine with the current master (as of 02/10/2016, commit 073df63) iff <tt style="background-color: rgb(245, 245, 245); border: 1px solid rgb(204, 204, 204); border-top-left-radius: 2px; border-top-right-radius: 2px; border-bottom-right-radius: 2px; border-bottom-left-radius: 2px; padding: 1px 3px; background-position: initial initial; background-repeat: initial initial;" class="">myFunction</tt> is a global function and not a method in a class</li></ul></div></div>_______________________________________________<br class="">swift-dev mailing list<br class=""><a href="mailto:swift-dev@swift.org" class="">swift-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-dev" class="">https://lists.swift.org/mailman/listinfo/swift-dev</a><br class=""></div></blockquote></div><br class=""></div></div>_______________________________________________<br class="">swift-dev mailing list<br class=""><a href="mailto:swift-dev@swift.org" class="">swift-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-dev" class="">https://lists.swift.org/mailman/listinfo/swift-dev</a><br class=""></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></div></div></body></html>