<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">
Bill et al,<div>                I haven't really thought this through (I've never been a fan of exception specifications),</div><div>but it seems that inlining functions that do have exception specifications, and hence filter</div><div>operands in their landing-pads, isn't so obvious...</div><div><br></div><div>if  you want to  inline</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">      </span>void foo () throw() { ... }<span class="Apple-tab-span" style="white-space:pre">         </span>// empty throw() list means "no-throw"</div><div><br></div><div>into a function that does allow exceptions to be propagated out, then you'll have a hard time</div><div>combining their landing pads !</div><div><br></div><div>it seems, at least on first thought, that having more than one filter list in a landing pad isn't</div><div>useful ?  (assuming the only way to get more than one is from inlining ?)</div><div><br></div><div><br></div><div>-Peter Lawrence.</div><div><br></div><div><br></div><div><br><div><div>On Aug 3, 2011, at 12:35 AM, <a href="mailto:llvmdev-request@cs.uiuc.edu">llvmdev-request@cs.uiuc.edu</a> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><blockquote type="cite"><p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">yes there is something about the order :)<span class="Apple-converted-space">  </span>When front-ends output code, all</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">catches come before filters, but after inlining you can get: catches, filters,</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">catches, filters etc and this ordering needs to be preserved.<span class="Apple-converted-space">  </span>Also, filters</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">are different from catches: filter ty_1, ty_2, ..., ty_N matches any exception</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">that would not be caught by any of ty_1, ty_2, ..., ty_N.<span class="Apple-converted-space">  </span>This is quite</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">different to filter ty_1, filter ty_2, ..., filter ty_N.<span class="Apple-converted-space">  </span>For example, suppose</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">you throw ty_2.<span class="Apple-converted-space">  </span>Then the filter ty_1, ty_2, ..., ty_N wouldn't match that,</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">but filter ty_1 would.</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px; font: 12.0px Monaco; min-height: 16.0px"><br></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">So filter ty_1, ..., ty_N makes sense; but I don't think catch ty_1, ..., ty_N</font></p> <p style="margin: 0.0px 0.0px 0.0px 10.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">makes sense.</font></p> </blockquote><p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px"><br></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">Agreed.<span class="Apple-converted-space">  </span>Other notes: a zero-type filter is meaningful (and pretty</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">common ? it's the result of 'throw()'), but the ordering of the cleanup</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">bit is not, so I would suggest this grammar:</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px"><br></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">Instruction ::= 'landingpad' Type 'personality' TypeAndValue 'cleanup'? LandingPadClause*</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">LandingPadClause ::= 'catch' TypeAndValue</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">LandingPadClause ::= 'filter' TypeAndValue*</font></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px"><br></p> <p style="margin: 0.0px 0.0px 0.0px 0.0px"><font face="Monaco" size="3" style="font: 12.0px Monaco">John.</font></p> </blockquote></div><br></div></body></html>