<div dir="ltr"><div><a href="http://forum.dlang.org/post/xpmpakmusudanwuzzezl@forum.dlang.org">http://forum.dlang.org/post/xpmpakmusudanwuzzezl@forum.dlang.org</a><br></div><a href="https://issues.dlang.org/show_bug.cgi?id=9631">https://issues.dlang.org/show_bug.cgi?id=9631</a><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 30, 2017 at 1:07 PM, Biotronic via Digitalmars-d-learn <span dir="ltr"><<a href="mailto:digitalmars-d-learn@puremagic.com" target="_blank">digitalmars-d-learn@puremagic.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tuesday, 30 May 2017 at 10:46:12 UTC, Andrew Edwards wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Tuesday, 30 May 2017 at 10:37:58 UTC, Biotronic wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Tuesday, 30 May 2017 at 10:31:24 UTC, Daniel Kozak wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
import std.traits : fqn = fullyQualifiedName;<br>
</blockquote>
<br>
Darnit. I just googled the template and got a result talking about fqn!T. So yeah - this code:<br>
<br>
import std.traits;<br>
<br>
pragma(msg, fullyQualifiedName!ImVec2);<br>
pragma(msg, fullyQualifiedName!(typeof(Cal<wbr>cTextSize(label.ptr, null, true))));<br>
<br>
--<br>
Biotronic<br>
</blockquote>
<br>
This is exactly the cause. Output is follows:<br>
<br>
internal.ImVec2<br>
types.ImVec2<br>
<br>
I'm leveraging types as I try to do my own port of the lib so CalcTextSize is returning an instance of ImVec2 as defined types and I'm trying to assign to one I have declared in internal.<br>
<br>
Thanks.<br>
</blockquote>
<br></div></div>
Pleasure. :)<br>
<br>
I don't know why you have two different ImVec2s, but you may have good reasons to. If they need to be separate, you'll need to write a conversion function between the two for the cases where you have one and want the other. This could be the constructor or opAssign, or a standalone function if you want to be more explicit about it.<br>
<br>
I'd argue that error message could be improved upon, btw.<br>
<br>
--<br>
Simen<br>
</blockquote></div><br></div>