[geos-devel] Death to auto_ptr?

Martin Davis mtnclimb at gmail.com
Tue Jan 29 18:27:09 PST 2019


Yes...  was just thinking that the most common case should be
highlighted/encouraged by making a typedef.

Whatever the most common case is...

On Tue, Jan 29, 2019 at 6:12 PM Paul Ramsey <pramsey at cleverelephant.ca>
wrote:

> Because you don’t always just use the Ptr, because you’re in a crazy mixed
> code base and you might need to call the get() method or use std::move() or
> any number of things that require knowing that, yes, actually you’re using
> a unique_ptr<>
>
> P
>
> On Jan 29, 2019, at 5:19 PM, Martin Davis <mtnclimb at gmail.com> wrote:
>
> Well, I raised a slightly dissenting opinion to removing the typedefs, and
> so did strk.
>
> Why not use a nice short name like GeomPtr to hide those ugly and
> hard-to-type <> ?
>
> @dbaston: there are many reasons for encapsulation.  One worthy goal is to
> provide a simpler mental model...
>
>
>
> On Tue, Jan 29, 2019 at 11:56 AM Paul Ramsey <pramsey at cleverelephant.ca>
> wrote:
>
>> Ah, yes, I had svn-3.5 checked out when I was running those searches.
>> Whooops.
>>
>> Not much objection to getting rid of the typedefs [2] that I can see.
>> Unless we really thing c++ is going to change the smart pointer
>> implementations yet again. (an open question, I suppose)
>>
>> P
>>
>> [2]
>> https://lists.osgeo.org/pipermail/geos-devel/2018-December/008750.html
>>
>> On Jan 29, 2019, at 11:53 AM, Daniel Baston <dbaston at gmail.com> wrote:
>>
>> I think auto_ptr has been removed from master already, no? I'd prefer to
>> lose the typedefs as well, but last time we brought that up I recall there
>> being some disagreement.
>>
>> Dan
>>
>> On Tue, Jan 29, 2019 at 2:19 PM Paul Ramsey <pramsey at cleverelephant.ca>
>> wrote:
>>
>>> Any reason not to renovate the code base and remote the various uses
>>> of auto_ptr in favour of unique_ptr and strip out the various typedefs
>>> at the same time so that we uniformly just use std::unique_ptr<> right
>>> in code where folks can see it?
>>>
>>> P.
>>> _______________________________________________
>>> geos-devel mailing list
>>> geos-devel at lists.osgeo.org
>>> https://lists.osgeo.org/mailman/listinfo/geos-devel
>>
>> _______________________________________________
>> geos-devel mailing list
>> geos-devel at lists.osgeo.org
>> https://lists.osgeo.org/mailman/listinfo/geos-devel
>>
>>
>> _______________________________________________
>> geos-devel mailing list
>> geos-devel at lists.osgeo.org
>> https://lists.osgeo.org/mailman/listinfo/geos-devel
>
> _______________________________________________
> geos-devel mailing list
> geos-devel at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/geos-devel
>
>
> _______________________________________________
> geos-devel mailing list
> geos-devel at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/geos-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geos-devel/attachments/20190129/6e6206ea/attachment-0001.html>


More information about the geos-devel mailing list