Future of string lambda functions/string predicate functions

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Tue Aug 13 17:48:29 PDT 2013


On 8/11/13 11:46 AM, Walter Bright wrote:
> On 8/11/2013 9:26 AM, Andrei Alexandrescu wrote:
>> There's a related issue that I think we must solve before deciding
>> whether or
>> not we should deprecate string lambdas. Consider:
>>
>> void main() {
>>      import std.range;
>>      SortedRange!(int[], "a > b") a;
>>      SortedRange!(int[], "a > b") b;
>>      b = a;
>>      SortedRange!(int[], (a, b) => a > b) c;
>>      SortedRange!(int[], (a, b) => a > b) d;
>>      d = c;
>> }
>>
>> The last line fails to compile because D does not currently have a
>> good notion
>> of comparing lambdas for equality.
>
> Bugzilla?

http://d.puremagic.com/issues/show_bug.cgi?id=10819

Andrei



More information about the Digitalmars-d mailing list