<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=""><br class=""><div><blockquote type="cite" class=""><div class="">On May 29, 2015, at 10:51 AM, escha <<a href="mailto:escha@apple.com" class="">escha@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px; color: rgb(0, 132, 0);"><span class="" style=""><br class="Apple-interchange-newline">    </span>/// Returns a type large enough to hold any valid shift amount - before type</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px; color: rgb(0, 132, 0);"><span class="" style="">   <span class="Apple-converted-space"> </span></span>/// legalization these can be huge.</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px;">   <span class="Apple-converted-space"> </span><span class="" style="color: rgb(79, 129, 135);">EVT</span><span class="Apple-converted-space"> </span>getShiftAmountTy(<span class="" style="color: rgb(79, 129, 135);">EVT</span><span class="Apple-converted-space"> </span>LHSTy) {</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px; color: rgb(209, 47, 27);"><span class="" style="">     <span class="Apple-converted-space"> </span></span><span class="" style="color: rgb(120, 73, 42);">assert</span><span class="" style="">(LHSTy.</span><span class="" style="color: rgb(49, 89, 93);">isInteger</span><span class="" style="">() &&<span class="Apple-converted-space"> </span></span>"Shift amount is not an integer type!"<span class="" style="">);</span></div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px;">     <span class="Apple-converted-space"> </span><span class="" style="color: rgb(187, 44, 162);">if</span><span class="Apple-converted-space"> </span>(LHSTy.<span class="" style="color: rgb(49, 89, 93);">isVector</span>())</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px;">       <span class="Apple-converted-space"> </span><span class="" style="color: rgb(187, 44, 162);">return</span><span class="Apple-converted-space"> </span>LHSTy;</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px; color: rgb(49, 89, 93);"><span class="" style="">     <span class="Apple-converted-space"> </span></span><span class="" style="color: rgb(187, 44, 162);">return</span><span class="" style=""> </span><span class="" style="color: rgb(79, 129, 135);">LegalTypes</span><span class="" style=""><span class="Apple-converted-space"> </span>?<span class="Apple-converted-space"> </span></span><span class="" style="color: rgb(79, 129, 135);">TLI</span><span class="" style="">.</span>getScalarShiftAmountTy<span class="" style="">(LHSTy)</span></div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px;">                        :<span class="Apple-converted-space"> </span><span class="" style="color: rgb(79, 129, 135);">TLI</span>.<span class="" style="color: rgb(49, 89, 93);">getPointerTy</span>();</div><div class="" style="font-family: Menlo; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; margin: 0px;">    }</div><br class="Apple-interchange-newline"></div></blockquote></div><br class=""><div class="">I didn’t know about this one. Why does this exist? This seems insane. Does anything break if you replace everything with TLI.getShiftAmountTy()?</div></body></html>