Re: Removing an object from a range

2010-12-13 Thread Jesse Phillips
Andrej Mitrovic Wrote: > Does anyone know if there's any way I can get special highlighting for > lambda functions in say, Vim? It gets hard to distinguish between > regular parameters and one-liner lambdas, if I could change the > background color of a lambda it could really help out.. Off the t

Re: Removing an object from a range

2010-12-13 Thread Andrej Mitrovic
Does anyone know if there's any way I can get special highlighting for lambda functions in say, Vim? It gets hard to distinguish between regular parameters and one-liner lambdas, if I could change the background color of a lambda it could really help out.. On 12/13/10, Andrej Mitrovic wrote: > On

Re: Removing an object from a range

2010-12-13 Thread Andrej Mitrovic
On 12/13/10, Steven Schveighoffer wrote: > does this work? > Yes, ty. But I think there's a typo in std.algorithm.remove: Range remove(alias pred, SwapStrategy s = SwapStrategy.stable, Range)(Range range); Reduces the length of the bidirectional range range by only keeping elements that sati

Re: Removing an object from a range

2010-12-13 Thread spir
On Sun, 12 Dec 2010 20:43:12 -0500 "Andrej M." wrote: > I can't seem to find an easy remove method in std.algorithm that takes an > object and a range (an array in this case) and removes any matches from the > range. I'm using this snippet for now: > > private DrawingElement[] elements; > > p

Re: Removing an object from a range

2010-12-13 Thread Steven Schveighoffer
On Sun, 12 Dec 2010 20:43:12 -0500, Andrej M. wrote: I can't seem to find an easy remove method in std.algorithm that takes an object and a range (an array in this case) and removes any matches from the range. I'm using this snippet for now: private DrawingElement[] elements; public overr

Re: Removing an object from a range

2010-12-12 Thread bearophile
Jonathan M Davis: > They're both based on C++ (though C# is also heavily based on Java which is > based on C++). D probably does take some features from C# (such as > delegates), > but D has taken features from a number of different languages. I doubt that > anything in C# is based on anything

Re: Removing an object from a range

2010-12-12 Thread Andrej Mitrovic
On 12/13/10, Matthias Walter wrote: > On 12/12/2010 08:43 PM, Andrej M. wrote: >> I can't seem to find an easy remove method in std.algorithm that takes an >> object and a range (an array in this case) and removes any matches from >> the range. I'm using this snippet for now: >> >> private Drawing

Re: Removing an object from a range

2010-12-12 Thread Matthias Walter
On 12/12/2010 08:43 PM, Andrej M. wrote: > I can't seem to find an easy remove method in std.algorithm that takes an > object and a range (an array in this case) and removes any matches from the > range. I'm using this snippet for now: > > private DrawingElement[] elements; > > public override vo

Re: Removing an object from a range

2010-12-12 Thread Jonathan M Davis
On Sunday 12 December 2010 18:35:38 Andrej Mitrovic wrote: > On a side note I have to admit I've never programmed in C# before, but > I don't seem to have much trouble understanding it. From the looks of > it, the two languages borrow a lot from each other, and have very > similar syntax. They're

Re: Removing an object from a range

2010-12-12 Thread Andrej Mitrovic
On a side note I have to admit I've never programmed in C# before, but I don't seem to have much trouble understanding it. From the looks of it, the two languages borrow a lot from each other, and have very similar syntax. On 12/13/10, Andrej Mitrovic wrote: > On 12/13/10, Jonathan M Davis wrote

Re: Removing an object from a range

2010-12-12 Thread Andrej Mitrovic
On 12/13/10, Jonathan M Davis wrote: > I created an enhancement request for it: http://is.gd/iDSqj > > - Jonathan M Davis > Thanks!

Re: Removing an object from a range

2010-12-12 Thread Jonathan M Davis
On Sunday 12 December 2010 17:43:12 Andrej M. wrote: > I can't seem to find an easy remove method in std.algorithm that takes an > object and a range (an array in this case) and removes any matches from > the range. I'm using this snippet for now: > > private DrawingElement[] elements; > > public

Removing an object from a range

2010-12-12 Thread Andrej M.
I can't seem to find an easy remove method in std.algorithm that takes an object and a range (an array in this case) and removes any matches from the range. I'm using this snippet for now: private DrawingElement[] elements; public override void Remove(DrawingElement d) { foreach (i, child;