The D2 dictionary chalenge.

2014-06-27 Thread Basile Burg via Digitalmars-d-learn
Try to make a faster one than http://dpaste.dzfl.pl/aa2ad03cb0dd Post your reply here, existing entries must be included.

Re: alias overloaded function template

2014-11-11 Thread Basile Burg via Digitalmars-d-learn
On Tuesday, 11 November 2014 at 19:36:12 UTC, Lemonfiend wrote: D is fine with alias this overloaded function: --- void foo(int t) {} void foo(int t, int i) {} alias bar = foo; --- But isn't as happy aliasing these function templates: --- void foo(T)(T t) {} void foo(T)(T t, int i) {} alias

Is it possible to use an UDA to generate a struct inside a class ?

2014-12-30 Thread Basile Burg via Digitalmars-d-learn
I have a struct used to describe a property[1]. Its standard usage is represented in this simple example: |class Bar { |private uint fField0; |private izPropDescriptor!uint descrField0; |this() { |descrField0.define(field0, field0, field0); |} |public void

Re: Is it possible to use an UDA to generate a struct inside a class ?

2014-12-30 Thread Basile Burg via Digitalmars-d-learn
On Tuesday, 30 December 2014 at 19:05:23 UTC, Ali Çehreli wrote: On 12/30/2014 09:42 AM, Basile Burg wrote: Can a descriptor be created using my attribute ? How ? Here is a quick and dirty solution: import std.string; struct PropertyDescriptor { string type; string name; string

Re: Is it possible to use an UDA to generate a struct inside a class ?

2015-01-01 Thread Basile Burg via Digitalmars-d-learn
On Tuesday, 30 December 2014 at 19:18:41 UTC, Basile Burg wrote: On Tuesday, 30 December 2014 at 19:05:23 UTC, Ali Çehreli wrote: On 12/30/2014 09:42 AM, Basile Burg wrote: Ok, thx. I see the trick: mixin (propertyInjections!C); Introspection inside each class. I don't find this solution

Re: Is it possible to use an UDA to generate a struct inside a class ?

2015-01-01 Thread Basile Burg via Digitalmars-d-learn
On Thursday, 1 January 2015 at 21:15:27 UTC, Ali Çehreli wrote: On 01/01/2015 09:35 AM, Basile Burg wrote: On Tuesday, 30 December 2014 at 19:18:41 UTC, Basile Burg wrote: an ICE (every compiler crash is an ICE right ?), Yes, the compiler should never crash but produce an error message.

Re: How is D doing?

2016-02-08 Thread Basile Burg via Digitalmars-d-learn
On Tuesday, 22 December 2015 at 11:42:42 UTC, bachmeier wrote: 1. Downloads of the DMD compiler have been fluctuating between 1000 and 1600 per day: http://erdani.com/d/downloads.daily.png To this you can add 75dl per day for ldc: