<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><blockquote type="cite" class=""><div class="">On May 20, 2016, at 1:25 PM, Антон Жилин <<a href="mailto:antonyzhilin@gmail.com" class="">antonyzhilin@gmail.com</a>> wrote:</div><div class=""><div dir="ltr" class="">Inline:<br class=""><div class="gmail_extra"><br class=""><div class="gmail_quote">2016-05-20 20:58 GMT+03:00 John McCall <span dir="ltr" class=""><<a href="mailto:rjmccall@apple.com" target="_blank" class="">rjmccall@apple.com</a>></span>:</div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word" class=""><div class="">The transitivity rule plus the ability to define precedence relationships in both directions on a new precedence group allows a new precedence group to create a precedence relationship between existing unrelated precedence groups. This should be forbidden.</div></div></blockquote><div class=""><br class=""></div><div class="">Agreed, although there is an alternate solution to allow global-scope relationship definition.</div><div class="">Trying to write it formally:</div><div class=""><br class=""></div><div class="">====begin====</div><div class="">Precedence relationships that, by transitivity rule, create relationship between two imported groups, is an error. Example:</div><div class=""><br class=""></div><div class="">// Module X</div><div class="">precedencegroup A { }</div><div class="">precedencegroup C { }</div><div class=""><br class=""></div><div class="">// Module Y</div><div class="">import X</div><div class="">precedencegroup B { precedence(> A) precedence(< C) }</div><div class=""><br class=""></div><div class="">This results in compilation error "B uses transitivity to define relationship between imported groups A and C".</div><div class="">The rationale behind this is that otherwise one can create relationships between standard precedence groups that are confusing for the reader.</div></div></div></div></div></blockquote><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class="gmail_extra"><div class="gmail_quote"><div class="">====end====</div></div></div></div></div></blockquote><div><br class=""></div>Seems good to me.</div><div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word" class=""><div class="">What's the purpose of equality relationships between precedence groups?</div></div></blockquote><div class=""><br class=""></div><div class="">Agreed, will remove.</div></div></div></div></div></blockquote><div><br class=""></div>Ok.</div><div> <br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word" class=""><div class="">Your proposal should call out the special treatment of the Assignment and Ternary groups.</div></div></blockquote><div class=""><br class=""></div><div class="">Do you mean that most operators should define greater precedence than Assignment / Ternary? Or there should be some other special treatment?<br class=""></div></div></div></div></div></blockquote><div><br class=""></div></div>Just that they have implicit members.<div class=""><br class=""></div><div class="">John.</div></body></html>