<div dir="ltr">Proposal Link: <a href="https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md">https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md</a><div><br></div><div>I'm a +1 on the proposal, I just have a few small questions and suggestions after giving it a brief read.</div><div><br></div><div>1) I'm not thrilled about the name "unkeyedContainer()" and related names. Would "sequentialContainer" or something along those lines be a better name? The fact that it can encode several, heterogeneous values in a fixed sequence seems to be the most salient feature of it that distinguishes it from the keyed containers and the single value containers.</div><div><br></div><div>2) I feel like the reasoning behind the design for the CodingUserInfoKey isn't clearly articulated, but it seems a bit odd to me. First off, I'm confused why with the current design, the declaration isn't simply:</div><div><br></div><div>protocol CodingUserInfoKey: CodingKey, Hashable {} </div><div><br></div><div>I tried mocking something up with the shipping Swift 3.1, and got the following error:</div><div><br></div><div>> using 'CodingUserInfoKey' as a concrete type conforming to protocol 'Hashable' is not supported<br></div><div><br></div><div>So maybe it's just a question of lack of compiler support. Still, I feel that the lack of a connection between the CodingKey and the CodingUserInfoKey types is fairly confusing.</div><div><br></div><div>To be more concrete but way more speculative, I'm assuming that current design one is intended to declare all their keys in an enum like,</div><div><br></div><div>enum SomeType.Key: CodingKey {</div><div> case foo</div><div> case bar</div><div> // ...</div><div> case metaKey1</div><div> case metaKey2</div><div>}</div><div><br></div><div>And then write an init? extension for CodingUserInfoKey.</div><div><br></div><div>It seems more natural however to me to leverage the nested container support instead. What exactly that design would look like is unclear to me—do you return a value that implements Encoder? Do you add duplicate nestedKeyedEncoder for the userInfo case? but it seems more of a clean fit with the rest of the API than exposing a dictionary.</div><div><br></div><div>Both pretty minor issues when considered with all the great ideas in the API. Looking forward to reviewing 0167 as well!</div><div><br></div><div>Cheers,</div><div>-C<br><br><div class="gmail_quote"><div dir="ltr">On Thu, Apr 6, 2017 at 2:10 PM Douglas Gregor <<a href="mailto:dgregor@apple.com">dgregor@apple.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class="gmail_msg"><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">Hello Swift community,</p><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">The review of SE-0166 "Swift Archival & Serialization" begins now and runs through April 12, 2017. The proposal is available here:</p><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);background-color:rgb(255,255,255)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg"><font color="#6a737d" face="-apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol" size="3" class="gmail_msg"><a href="https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md" class="gmail_msg" target="_blank">https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md</a></font></div></blockquote><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">Reviews are an important part of the Swift evolution process. All reviews should be sent to the swift-evolution mailing list at</p><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;color:rgb(106,115,125);border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg"><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" style="box-sizing:border-box;background-color:transparent;color:rgb(3,102,214);text-decoration:none" class="gmail_msg" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a></div></blockquote><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">or, if you would like to keep your feedback private, directly to the review manager. When replying, please try to keep the proposal link at the top of the message:</p><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);background-color:rgb(255,255,255)" class="gmail_msg"><p style="color:rgb(106,115,125);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;box-sizing:border-box;margin-top:0px;margin-bottom:16px" class="gmail_msg">Proposal link:</p><blockquote style="box-sizing:border-box;margin:0px;padding:0px 1em;border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg"><font color="#6a737d" face="-apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol" size="3" class="gmail_msg"><a href="https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md" class="gmail_msg" target="_blank">https://github.com/apple/swift-evolution/blob/master/proposals/0166-swift-archival-serialization.md</a></font></div></blockquote></blockquote><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;color:rgb(106,115,125);border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg">Reply text</div></blockquote><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;color:rgb(106,115,125);border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg"><blockquote style="box-sizing:border-box;margin:0px;padding:0px 1em;border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg">Other replies</div></blockquote></blockquote><h5 style="box-sizing:border-box;margin-top:24px;margin-bottom:16px;font-size:0.875em;line-height:1.25;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';background-color:rgb(255,255,255)" class="gmail_msg"><a id="m_-4654868421238699342user-content-what-goes-into-a-review-1" class="m_-4654868421238699342anchor gmail_msg" href="https://github.com/apple/swift-evolution/blob/master/process.md#what-goes-into-a-review-1" style="box-sizing:border-box;background-color:transparent;color:rgb(3,102,214);text-decoration:none;float:left;padding-right:4px;line-height:1" target="_blank"><u class="gmail_msg"></u><u class="gmail_msg"></u><u class="gmail_msg"></u><u class="gmail_msg"></u></a>What goes into a review?</h5><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">The goal of the review process is to improve the proposal under review through constructive criticism and, eventually, determine the direction of Swift. When writing your review, here are some questions you might want to answer in your review:</p><ul style="box-sizing:border-box;padding-left:2em;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg"><li style="box-sizing:border-box" class="gmail_msg">What is your evaluation of the proposal?</li><li style="box-sizing:border-box;margin-top:0.25em" class="gmail_msg">Is the problem being addressed significant enough to warrant a change to Swift?</li><li style="box-sizing:border-box;margin-top:0.25em" class="gmail_msg">Does this proposal fit well with the feel and direction of Swift?</li><li style="box-sizing:border-box;margin-top:0.25em" class="gmail_msg">If you have used other languages or libraries with a similar feature, how do you feel that this proposal compares to those?</li><li style="box-sizing:border-box;margin-top:0.25em" class="gmail_msg">How much effort did you put into your review? A glance, a quick reading, or an in-depth study?</li></ul><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">More information about the Swift evolution process is available at</p><blockquote style="box-sizing:border-box;margin:0px 0px 16px;padding:0px 1em;color:rgb(106,115,125);border-left-width:0.25em;border-left-style:solid;border-left-color:rgb(223,226,229);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg"><div style="box-sizing:border-box;margin-top:0px;margin-bottom:0px" class="gmail_msg"><a href="https://github.com/apple/swift-evolution/blob/master/process.md" style="box-sizing:border-box;background-color:transparent;color:rgb(3,102,214);text-decoration:none" class="gmail_msg" target="_blank">https://github.com/apple/swift-evolution/blob/master/process.md</a></div></blockquote><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">Thank you,</p><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">-Doug</p><p style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Helvetica,Arial,sans-serif,'Apple Color Emoji','Segoe UI Emoji','Segoe UI Symbol';font-size:16px;background-color:rgb(255,255,255)" class="gmail_msg">Review Manager</p></div>_______________________________________________<br class="gmail_msg">
swift-evolution-announce mailing list<br class="gmail_msg">
<a href="mailto:swift-evolution-announce@swift.org" class="gmail_msg" target="_blank">swift-evolution-announce@swift.org</a><br class="gmail_msg">
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution-announce" rel="noreferrer" class="gmail_msg" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution-announce</a><br class="gmail_msg">
</blockquote></div></div></div>