<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=""><div class="">What do you think of:</div><div class=""><br class=""></div><div class="">#file, #lineNumber, #column, #symbol (e.g. Swift.Dictionary.init), #module, #contextDictionary</div><div class=""><br class=""></div><div class="">and calling it a day?</div><div class=""><br class=""></div><div class="">* using contextDictionary allows expandability and can subsume all existing context elements, indexed presumably by the same names</div><div class="">* renaming function to symbol takes care of self.dynamicType as well</div><div class="">* file and lineNumbers are gimmes</div><div class="">* column is apparently well liked by some (not going to kick someone's dog on this)</div><div class="">* adding module fills a big hole.</div><div class=""><br class=""></div><div class="">No tuples for Doug, covers some of Chris's points.</div><div class=""><br class=""></div><div class="">-- E</div><div class=""><br class=""></div><div><blockquote type="cite" class=""><div class="">On Jan 24, 2016, at 4:12 PM, Remy Demarest &lt;<a href="mailto:remy.demarest@gmail.com" class="">remy.demarest@gmail.com</a>&gt; 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="">+1 I love the idea of having not-only consistent naming convention for compiler-magic code starting with #.<div class=""><br class=""></div><div class="">And I also love the idea that source location would be one object that you can print to get the full story while still retaining the possibility to use each individual components as needed, which is probably the rarer case. I never find myself wanting only some of properties and usually don't include them simply because it takes longer to write the format properly, if I can get them all in one go it's certainly a win.<div class=""><div class=""><br class=""><div class="">
<div class="">Remy Demarest</div><div class=""><a href="mailto:remy.demarest@gmail.com" class="">remy.demarest@gmail.com</a></div><div class=""><br class=""></div><br class="Apple-interchange-newline">
</div>
<br class=""><div class=""><blockquote type="cite" class=""><div class="">Le 23 janv. 2016 à 18:46, Erica Sadun via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; a écrit :</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=""><div class="">Pull request:&nbsp;<a href="https://github.com/apple/swift-evolution/pull/116" class="">https://github.com/apple/swift-evolution/pull/116</a></div><div class=""><br class=""></div><div class="">-- E</div><div class=""><br class=""></div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Jan 22, 2016, at 5:40 PM, Chris Lattner &lt;<a href="mailto:clattner@apple.com" class="">clattner@apple.com</a>&gt; 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=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Jan 22, 2016, at 1:43 PM, Jack Lawrence &lt;<a href="mailto:jackl@apple.com" class="">jackl@apple.com</a>&gt; 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="">Indeed. Here’s the grammar from TSPL:<div class=""><br class=""></div><div class=""><div style="border: 0px; font-size: 14px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; font-family: Helvetica, Arial, sans-serif;" class=""><span class="syntax-def-name" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(128, 128, 128); font-style: italic;">line-control-statement&nbsp;</span><span class="arrow" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 0px 0px 4px; vertical-align: baseline; color: rgb(128, 128, 128);">→&nbsp;</span><code class="literal" style="border: 0px; font-size: 0.86em; margin: 0px; outline: 0px; padding: 0px 4px; vertical-align: baseline; font-family: Menlo, monospace; font-weight: 600; word-wrap: break-word;">#line­</code></div><div style="border: 0px; font-size: 14px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; font-family: Helvetica, Arial, sans-serif;" class=""><a name="//apple_ref/doc/uid/TP40014097-CH38-NoLink_926" style="border: 0px; margin: -85px 0px 0px; outline: 0px; padding: 85px 0px 0px; vertical-align: baseline; display: block; width: 0px; height: 0px; color: rgb(0, 136, 204);" class=""></a><span class="syntax-def-name" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(128, 128, 128); font-style: italic;">line-control-statement&nbsp;</span><span class="arrow" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 0px 0px 4px; vertical-align: baseline; color: rgb(128, 128, 128);">→&nbsp;</span><code class="literal" style="border: 0px; font-size: 0.86em; margin: 0px; outline: 0px; padding: 0px 4px; vertical-align: baseline; font-family: Menlo, monospace; font-weight: 600; word-wrap: break-word;">#line­</code><span class="syntactic-cat" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 4px; vertical-align: baseline; font-style: italic; word-break: keep-all;"><a href="https://developer.apple.com/library/ios/documentation/Swift/Conceptual/Swift_Programming_Language/Statements.html#//apple_ref/swift/grammar/line-number" data-renderer-version="2" data-id="//apple_ref/swift/grammar/line-number" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(0, 136, 204); text-decoration: none;" class="">line-number</a>­</span><span class="syntactic-cat" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 4px; vertical-align: baseline; font-style: italic; word-break: keep-all;"><a href="https://developer.apple.com/library/ios/documentation/Swift/Conceptual/Swift_Programming_Language/Statements.html#//apple_ref/swift/grammar/file-name" data-renderer-version="2" data-id="//apple_ref/swift/grammar/file-name" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(0, 136, 204); text-decoration: none;" class="">file-name</a>­</span></div><div style="border: 0px; font-size: 14px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; font-family: Helvetica, Arial, sans-serif;" class=""><a name="//apple_ref/doc/uid/TP40014097-CH38-NoLink_927" style="border: 0px; margin: -85px 0px 0px; outline: 0px; padding: 85px 0px 0px; vertical-align: baseline; display: block; width: 0px; height: 0px; color: rgb(0, 136, 204);" class=""></a><span class="syntax-def-name" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(128, 128, 128); font-style: italic;">line-number&nbsp;</span><span class="arrow" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 0px 0px 4px; vertical-align: baseline; color: rgb(128, 128, 128);">→&nbsp;</span><span class="text-description" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline;">A decimal integer greater than zero</span></div><div style="border: 0px; font-size: 14px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; font-family: Helvetica, Arial, sans-serif;" class=""><a name="//apple_ref/doc/uid/TP40014097-CH38-NoLink_928" style="border: 0px; margin: -85px 0px 0px; outline: 0px; padding: 85px 0px 0px; vertical-align: baseline; display: block; width: 0px; height: 0px; color: rgb(0, 136, 204);" class=""></a><span class="syntax-def-name" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(128, 128, 128); font-style: italic;">file-name&nbsp;</span><span class="arrow" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 0px 0px 4px; vertical-align: baseline; color: rgb(128, 128, 128);">→&nbsp;</span><span class="syntactic-cat" style="border: 0px; margin: 0px; outline: 0px; padding: 0px 4px; vertical-align: baseline; font-style: italic; word-break: keep-all;"><a href="https://developer.apple.com/library/ios/documentation/Swift/Conceptual/Swift_Programming_Language/LexicalStructure.html#//apple_ref/swift/grammar/static-string-literal" data-renderer-version="2" data-id="//apple_ref/swift/grammar/static-string-literal" style="border: 0px; margin: 0px; outline: 0px; padding: 0px; vertical-align: baseline; color: rgb(0, 136, 204); text-decoration: none;" class="">static-string-literal</a>­</span></div></div></div></div></blockquote><br class=""></div><div class="">Huh ok, I forgot we supported that. &nbsp;We could handle that by requiring that form of #line to be at the start of a line, if necessary.</div><div class=""><br class=""></div><div class="">-Chris</div><br class=""></div></div></blockquote></div><br class=""></div></div>_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class=""></div></blockquote></div><br class=""></div></div></div></div></div></blockquote></div><br class=""></body></html>