[prev in list] [next in list] [prev in thread] [next in thread]
List: webkit-dev
Subject: Re: [webkit-dev] Get rid of RefPtr, replace with std::optional<Ref>?
From: Maciej Stachowiak <mjs () apple ! com>
Date: 2017-09-01 17:46:16
Message-ID: EE8D9B52-536E-4029-A062-09B7F8EA0A73 () apple ! com
[Download RAW message or body]
> On Sep 1, 2017, at 10:07 AM, Brady Eidson <beidson@apple.com> wrote:
>
>
>
> > On Sep 1, 2017, at 9:46 AM, Maciej Stachowiak <mjs@apple.com> wrote:
> > >
> > > Does RefPtr do anything for us today that std::optional<Ref> doesn't?
> >
> > The obvious things would be: uses less storage space
>
> Grumble. If that's true (which, thinking about it, of course it is true) this is \
> pretty much a nonstarter. So… nevermind.
It might be possible to make a specialization of std::optional<Ref> that avoids the \
overhead for a separate initialized bool. I'm not sure if it is wise to write \
specializations of standard library template classes though.
Regards,
Maciej
_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic