<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="">So, my friend <a href="http://twitter.com/harenson" class="">Harenson</a> was dialyzing some code where we’ve implemented egithub_webhook behaviour from <a href="https://hex.pm/packages/egithub" class="">egithub</a>, and he found this warning:</div><div class=""><br class=""></div><div class=""><pre style="box-sizing: border-box; overflow: auto; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 13.6px; margin-top: 0px; margin-bottom: 0px; line-height: 1.45; padding: 16px; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; word-wrap: normal; word-break: normal; color: rgb(51, 51, 51); widows: 1; background-color: rgb(247, 247, 247);" class=""><span class="pl-smi" style="box-sizing: border-box;">Callback</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">info</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">about</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">the</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">egithub_webhook</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">behaviour</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">is</span> <span class="pl-k" style="box-sizing: border-box; color: rgb(167, 29, 93);">not</span> <span class="pl-c1" style="box-sizing: border-box; color: rgb(0, 134, 179);">available</span></pre><div class=""><br class=""></div></div><div class="">Being a big fan of dialyzer myself, I immediately jumped in and tried to <i class="">fix </i>our code to avoid that warning.</div><div class="">But this time, it turns out, it seems like we actually found a bug in dialyzer.</div><div class="">We reduced the issue to its smallest possible expression and uploaded it <a href="https://github.com/elbrujohalcon/dialyzeit" class="">here</a>.</div><div class=""><br class=""></div><div class="">I’m pretty sure for most of you it will be just a curiosity, but just in case it actually helps someone, remember:</div><div class=""><br class=""></div><div class=""><b class="">Don’t define a callback and add a not exported function with the same name and arity to the same module in your libraries.</b></div><div class=""><b class=""><br class=""></b></div><div class="">At least, don’t do it until <a href="http://bugs.erlang.org/browse/ERL-72" class="">ERL-72</a> is fixed ;)</div><div class=""><br class=""></div><div class="">Cheers!</div><br class=""><div class="">
<div class=""><font face="Helvetica Neue" class=""><span style="font-size: 17px;" class=""><b class="">Fernando “Brujo” Benavides</b></span></font></div><div style="font-size: 15px;" class=""><a href="http://about.me/elbrujohalcon" class="">about.me/elbrujohalcon</a></div><div class=""><br class=""></div><br class="Apple-interchange-newline">
</div>
<br class=""></body></html>