Re: Why do Glib::ustring::operator[] and at() return values, not references?



On 28 June 2017 at 10:51, Daniel Boles <dboles src gmail com> wrote:
Yeah, I thought about that briefly but forgot by the time I was writing the email. I wonder whether sigc::trackable can help here, although maybe that's getting too complex to be worthwhile. 

In fact, that definitely sounds too complex for what we'd gain. We would do better just to tell users to be careful with lifetimes, as they must already do in various other places, than to impose a new base class on ustring.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]