<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=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jul 29, 2016, at 5:20 PM, Jacob Bandes-Storch via swift-evolution <<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Chris writes:<div class=""><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex" class="gmail_quote">- <b class="">Source stability features: </b>These should be relatively small, but important. For example, we need a “-std=swift3” sort of compiler flag. We may also add a way to conditionally enable larger efforts that are under development but not yet stable - in order to make it easier to experiment with them.</blockquote></div><div class=""><br class=""></div><div class=""><br clear="all" class=""><div class=""><div class="gmail_signature"><div dir="ltr" class=""><div class="">I am curious whether the team has thoughts on how to organize the compiler codebase in such a way that new features can be added, and possibly source-breaking changes made, while still keeping the old functionality around.</div><div class=""><br class=""></div><div class="">Are any obvious areas that will need refactoring to make this feasible? (Perhaps they could be turned into StarterBugs.)</div></div></div></div></div></div></div></blockquote><div><br class=""></div><div>I think this would be a great thing to do. We need a few things:</div><div><br class=""></div><div>- The actual compiler flag. It is worth bikeshedding how it is spelled. “-std=“ is good inspiration, but clearly the wrong specific name.</div><div><br class=""></div><div>- The implementation should be straight forward: the flag should get plumbed through to a field in swift::LangOptions. Code that diverges can then check it.</div><div><br class=""></div><div>- Handling divergence in the standard library is another big issue. We have some ideas here, but it depends on having the compiler work done anyway to hook into.</div><div><br class=""></div><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class=""><div class=""><div class="gmail_signature"><div dir="ltr" class=""><div class="">How many versions back would the compiler be expected to support? Should the Swift 5 compiler still support Swift 3 code?</div></div></div></div></div></div></div></blockquote></div><br class=""><div class="">To be determined. Swift 4 should definitely support Swift 3, but Swift 5 perhaps not. We can decide that when Swift 4 is winding down.</div><div class=""><br class=""></div><div class="">-Chris</div></body></html>