<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="">This will add a step that developers will have to remember when changing an ASSERT. &nbsp;There may be developers that want to knowingly keep the same tag. &nbsp;What about creating my own tag values? &nbsp;How will we guard against reusing a tag?</div><div class=""><br class=""></div>So what would be an appropriate tag for an ASSERT in a templated class that is in a .h file? &nbsp;An example would be the at() method in Vector.h:<div class=""><div style="margin: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp;&nbsp;T&amp; at(Checked&lt;size_t&gt; i)</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp; <span style="font-variant-ligatures: no-common-ligatures; background-color: #00e6e5" class="">{</span></div><div style="margin: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp; &nbsp; &nbsp; RELEASE_ASSERT(i &lt; size());</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp; &nbsp; &nbsp; return Base::buffer()[i];</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp; <span style="font-variant-ligatures: no-common-ligatures; background-color: #00e6e5" class="">}</span></div></div><div class="">I question having hundreds of ASSERTs in the code all with the same tag provides any benefit. &nbsp;These identically tagged ASSERTs are for guarding against unrelated out-of-bounds access checks.</div><div class=""><br class=""></div><div class="">If you say that we aren’t going to handle RELEASE_ASSERTs, these are the asserts that developers have said are the most important, in that we want to assert in a production build. &nbsp;In fact you might have an argument for tagging RELEASE_ASSERTs if we think it would improve debugging post release crashes.</div><div class=""><br class=""></div><div class="">- Michael</div><div class=""><div class=""><div class=""><br class=""></div><div class=""><div><blockquote type="cite" class=""><div class="">On Nov 6, 2014, at 12:34 PM, Said Abou-Hallawa &lt;<a href="mailto:sabouhallawa@apple.com" class="">sabouhallawa@apple.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class="">When the logical expression in the ASSERT is changed, you should do the following:<br class=""><br class="">- &nbsp;&nbsp;ASSERT_TAG(condition, “abcde”);<br class="">+ &nbsp;ASSERT(new_condition);<br class=""><br class="">Then the pre-build tagging tool will generate a new tag for the new assertion:<br class=""><br class="">+ &nbsp;ASSERT(new_condition, “fghij”);<br class=""><br class="">So the assertions do not get messed up with Bugzailla.<br class=""><br class="">The pre-build tool runs periodically only on Bot, maybe once every day and only on the touched files since it was last run. &nbsp;Then it commits only the changed files because of tagging. &nbsp;This should not add much to the build process.<br class=""><br class="">Both ASSERT and ASSERT_TAG should be supported. &nbsp;Since the developer should only add ASSERT and leave the tagging for the pre-build tagging tool.<br class=""><br class=""></div></blockquote></div><br class=""></div></div></div></body></html>