UDA failling to build when using delegate

bioinfornatics via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed Nov 5 14:02:49 PST 2014


On Wednesday, 5 November 2014 at 21:57:42 UTC, bioinfornatics
wrote:
> On Tuesday, 4 November 2014 at 22:06:03 UTC, Ali Çehreli wrote:
>> On 11/04/2014 01:58 PM, bioinfornatics wrote:
>>
>> >> test.d(40): Error: type Section!((letter) => letter == '>',
>> >> (letter) => letter == '\x0a') has no value
>>
>> You have this line:
>>
>>    @Section!(/* ... */)
>>
>> Although that is a type name, there is a bug somewhere and 
>> sometimes you have to use a 'value' as a UDA. (We talked about 
>> this recently but I don't remember the details.) So make it an 
>> object so that it is a 'value':
>>
>>    @Section!(/* ... */)()
>>
>> (You have another instance of that.)
>>
>> You will have to deal with the next set of error messages now. 
>> :-/
>>
>> Ali
>
> Thanks Ali
>
> If i understand well, that is a dmdfe bug ?
>
> i yes that is weird as using @Section!(/* ... */)() give to me
> something type of void then I can't filter to the desired  uda

Oh that is ok, I replaced

static if(is(attr : Section!T, T...))
by
static if(is(Section!(T, T)))


More information about the Digitalmars-d-learn mailing list