Meta / CTFE library

Jarrett Billingsley kb3ctd2 at yahoo.com
Mon Jun 23 06:13:19 PDT 2008


"Matthias Walter" <Matthias.Walter at st.ovgu.de> wrote in message 
news:g3nnn9$2pvf$1 at digitalmars.com...

> 3. here comes the point of my post: I'd like to know your whishes, what 
> should be in there, too! Has anyone found some special functions quiet 
> useful for his own CT-projects, or desired some functionality, he could 
> not implement?

I think it's a great idea.  I don't know how many times I've done some 
compile-time stuff and thought "someone's probably already solved this." 
And then I go digging in DDL.meta or PyD and usually find it ;)

> Have you further suggestions about such a library, either in design or 
> content?

You might already have this stuff, but I've got some compile-time stuff for 
things like getting a tuple of all the names of the fields of a 
struct/class/union (in D1; it's a horrid hack), finding the minimum number 
of arguments that a function can be called with, and converting between 
various Unicode encodings at runtime.  I've also got some scarier stuff --  
compile-time tuple qsort with custom predicates and template map, reduce, 
and range.

Having some kind of standard string <-> number conversion functions would 
probably save me ten minutes and 50 lines on everything I work on ;) 





More information about the Digitalmars-d mailing list