<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 29, 2016 at 3:51 PM, Santiago Fernández <span dir="ltr"><<a href="mailto:santif@gmail.com" target="_blank">santif@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><span class=""><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 29, 2016 at 9:21 AM, Benoit Chesneau <span dir="ltr"><<a href="mailto:bchesneau@gmail.com" target="_blank">bchesneau@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I have a function hackney_url:parse_url() returning a record #hackney_url{} . This record can be used internally but also externally by the applications that need it. Which requires for now to include "hackney_lib.hrl" . The record will likely change. On the other hands I am not sure I like to have to import the include file to get its definition (or copy this definition in another file, or just use the tuple) .</blockquote></div><br></div></span><div class="gmail_extra">You can provide functions to access data in #hackney_url{}, like this:<br><br></div><div class="gmail_extra">hackney:get_host(Url)<br><br></div><div class="gmail_extra">and it isn't required to include hackney_lib.hrl in client code.<br></div><div class="gmail_extra"><br clear="all"><div><div><div><br></div></div></div></div></div></blockquote><div><br></div><div>Yeah but like i said my initial mail, i think it's quite embarrassing when you could just pass a maps that already have this get function. On first thought thought :)</div><div><br></div><div>- benoit</div></div></div></div>