Boost logo

Boost :

From: Thore Karlsen (sid_at_[hidden])
Date: 2005-09-22 09:36:25


On Wed, 21 Sep 2005 18:21:23 -0400, David Abrahams
<dave_at_[hidden]> wrote:

>>> - The naming of arm/disarm methods of scope guard. They are used to change
>>> the activity status of the guard. Personally, I feel fine with them but the
>>> commonly used name for disabling the guard is "dismiss" and I just can't
>>> figure out its suitable counterpart in English. I wonder if anyone have a
>>> proposal about this.

>> How about "enable" and "disable"? Although I must admit that I never had
>> the need to re-enable a scope guard, and that I favor "dismiss" for
>> disabling.

>Another thought:
>
> g = 0;
>
>it's easy to arrange that only a literal zero works there.
>I don't love it, but maybe it will get your ideas flowing.

This is confusing to me. This makes it appear that the guard is disabled
for good, and can never be re-enabled. Same with "reset".

I like "dismiss" for disabling, but I don't think "summon", "guard", or
"post" intuitively make sense. "enable"/"disable" or
"activate"/"deactivate" sound better to my ears, unless there is a
better word to pair with "dismiss". To be honest, I'm not convinced that
too much focus on comparing this concept with a real-world guard is a
good thing.

-- 
Be seeing you.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk