Boy, std.bitmanip.bigEndianToNative is annoying to use
Jonathan M Davis via Digitalmars-d
digitalmars-d at puremagic.com
Fri May 22 12:48:20 PDT 2015
On Friday, 22 May 2015 at 19:44:59 UTC, H. S. Teoh wrote:
> On Fri, May 22, 2015 at 12:39:12PM -0700, H. S. Teoh via
> Digitalmars-d wrote:
> [...]
>> face.palm();
>> head.hang!inShame();
>> self.crawlBackTo(hole);
> [...]
>
> Truth be told, though, the error message was very unhelpful
> about it. It
> just says no templates were matched, no indication about the
> fact that
> the problem was caused by mismatched type lengths.
Well, I'm not sure how we could fix that. That's a general
problem with template constraints. You know that they aren't
passing, but you don't know _why_ they aren't passing. Though
maybe in this case, the docs could be improved to make it clearer
that if you're getting compilation errors, there's a decent
chance that you got the type sizes wrong.
- Jonathan M Davis
More information about the Digitalmars-d
mailing list