$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Eugene Lazutkin (eugene_lazutkin_at_[hidden])
Date: 2003-07-19 23:36:05
Inline.
"John Madsen" <johnmadsen_usenet_at_[hidden]> wrote in message
news:bfcu7q$jjm$2_at_main.gmane.org...
>
> I fail to see how COM is a relevant analogy. The smart_handle classes
I've
> proposed will work on all major platforms unlike COM. Several people have
COM was available on all major platforms. I still remember running it on
Solaris and HP-UX (?) long time ago.
> already suggested that it would be worthwhile for FILE*s and file
descriptors.
I am not in position to judge their reasons --- I never had this need. Maybe
I avoided their specific problems somehow. Or these problems are not
frequent enough. Anyway, I can speak only for myself. And I am not convinced
yet. :-)
> >Usually solution and problem go in pair. And problem goes before
solution.
> >In this case solution is our response to problem. Well, your comment
tells
> >me that we have a solution in search of a problem. Not that there's
anything
> >wrong with that.
>
> See point above.
Hmm. I expected that _you_ will tell in your proposal something like that:
"There is this huge set of problems. These are specific examples majority of
programmers are struggling with frequently. (Stone cold facts and examples).
And this is how I propose to change our hard life to the better.
(Solution)." :-) Something like that. Instead you proposed solution without
proofs of problem. I guess I had wrong expectations.
> Automatic conversions are well known sources of hard to find bugs. Six
In all cases? Well, programming itself is well known source of hard to find
bugs. :-) I don't think that this is valid argument in this particular case.
> characters hardly seems like a big deal.
And still nobody uses auto_ptr like this: p.get()->XXX(). :-) If we can
simplify our life, we should. If we can save 1 character in frequently used
idiom, we should.
> >Isn't it an overkill to use reference counting to put handles in vector?
Is
> >it the best solution for such problem? :-)
>
> Not necessarily. Please suggest another.
I have some ideas how to deal with this problem. But all of them fall
outside of discussion about smart handles.
Thanks,
Eugene