Implement AsRef for IriBuf to Iri
bbqsrc opened this issue ยท 3 comments
Hey, loving the crate!
I'm thinking about implementing AsRef for IriBuf. Anything I should know before I start, or otherwise, reasons I shouldn't do it? ๐
Hi, thanks for the interest ๐
I was planning on implementing AsRef<str>
and AsRef<PctStr>
systematically (when I have some time). Or do you mean AsRef<Iri>
/AsRef<IriRef>
? I guess those are needed too...
I think it's a good idea yeah, although it would be nice to go all the way through and implement it for every other types (Iri
, IriRef
, IriRefBuf
, Path
, PathBuf
, Authority
, etc.).
It is a fair amount of work... I could take care of it myself but i have a limited amount of times these days, it may take some. If you need AsRef
implemented for IriBuf
asap, I can accept a pull request with what you need, and I'll do the rest later.
Very reasonable, thanks. I might take a shot at the other things too while I'm there, so thanks for telling me your goals ๐
I did end up looking. AsRef for IriBuf can't work because there's nothing to hold the temporary reference to. :)