> On Sep 6, 2016, at 6:43 PM, Maciej Stachowiak wrote:
>
> RefPtr does also have regular release() though. I'm not sure if this is for a
> practical reason or just no one has fixed it yet.
It’s still around until we finish getting rid of PassRefPtr, that’s all.
> A wacky
> On Sep 6, 2016, at 5:27 PM, Darin Adler wrote:
>
>> On Sep 6, 2016, at 4:48 PM, Maciej Stachowiak wrote:
>>
>> STL smart pointers have a 0-argument reset for non-returning remove instead,
>> and convention seems to be to use swap() or move() for the
> On Sep 6, 2016, at 4:48 PM, Maciej Stachowiak wrote:
>
> STL smart pointers have a 0-argument reset for non-returning remove instead,
> and convention seems to be to use swap() or move() for the returning remove
> on a smart pointer. So an alternate possibility would be to
I thought about why release() seems subtly wrong to me for collections, but not
for smart pointers. Specifically, release() puts the focus on giving up
ownership, but the in the case of a collection, the most important thing is
removal from the collection, where giving up ownership is a detail
On Tue, 2016-09-06 at 11:12 -0700, Filip Pizlo wrote:
> FWIW, I still like release() better than move(). a = move(b) is a
> command to the system to move b to a. So, value =
> collection.move(key) feels like a command to the collection to move
> key to value, which is clearly not what is going
I think “take" is a fine word to indicate that you are taking a value from a
HashSet, just like “add" indicates you are adding to the set and remove
indicates you are “removing" from the set. It’s true that in all these cases
the caller is doing the thing, not the object, but it makes sense in
> On Sep 6, 2016, at 11:07 AM, Geoffrey Garen wrote:
>
> “take” grinds my gears too — though I’ve gotten used to it, more or less.
>
> I read “object.verb()” as a command, “verb”, directed at “object” (or
> sometimes as a question, “verb?”, directed at “object”). I think
“take” grinds my gears too — though I’ve gotten used to it, more or less.
I read “object.verb()” as a command, “verb”, directed at “object” (or sometimes
as a question, “verb?”, directed at “object”). I think most APIs are phrased
this way. And if I were Antonin Scalia, I would make the
On Tue, Sep 6, 2016 at 4:29 AM, Daniel Olegovich Lazarenko <
dani...@opera.com> wrote:
..
> * "take" - a typical name for collections like a blocking queue, heap and
> some others (usually ordered). If it's a collection's method, it's
> logically expected to return an item. The key distinction
On Mon, 2016-09-05 at 10:23 -0700, Filip Pizlo wrote:
> The use of "take" for these methods grinds my gears, for the same
> reason you were distracted: "take" describes the desires of the
> caller, but that doesn't work for me because I read
> "fred.makeCoffee()" as "makeCoffee()" being an
Hello,
For a WebKit observer like me:
* "release" - has a well-known meaning in Mac/Objective-C world. It's
expected to "free" the memory. Same as COM's IUnknown::Release, but
different from auto_ptr::release or unique_ptr::release (which don't free
the memory).
* "move" - has a well-known
11 matches
Mail list logo