D component programming is a joke (Was: Re: Component programming)

H. S. Teoh hsteoh at quickfur.ath.cx
Fri Aug 2 16:05:55 PDT 2013


On Fri, Aug 02, 2013 at 03:00:01PM -0700, H. S. Teoh wrote:
> On Fri, Aug 02, 2013 at 08:49:30PM +0200, Timon Gehr wrote:
[...]
> > I get the dreaded forward reference errors with at least DMD 2.060,
> > DMD 2.063 and DMD 2.063.2 and the 2.x build on dpaste.
> 
> Can you send me the error messages? I'll see if I can reorder the code
> to fix them.

I just checked DMD 2.063, and it appears that the error is caused by a
limitation in std.range.chunks in 2.063, where it requires slicing and
length, but formatYear can only give it an input range. This is kinda
sad, since that means I'll have to implement chunks myself on 2.063. :-/

I've no idea why it seems to be somehow conflated with an error from
invoking std.conv.to!() to convert from string to int; apparently some
kind of compiler bug that obscures the real problem with
std.range.chunks.


> > Git head gives me:
> > 
> > Error: undefined identifier '_xopCmp'
> > dmd: clone.c:690: FuncDeclaration*
> > StructDeclaration::buildXopCmp(Scope*): Assertion `s' failed.
> > Aborted (core dumped)
> 
> That's new. It was working as of yesterday; must've been a new
> regression in the commits since then?
[...]

Actually, I just pulled git HEAD again, and it's still working fine.
Maybe you just need to update your repo?


T

-- 
"Real programmers can write assembly code in any language. :-)" -- Larry Wall


More information about the Digitalmars-d mailing list