Albert Astals Cid <[email protected]> writes: > Hi guys, what do you think of us adding "some" of the C++11 features in > poppler?
Perfect!
> One that would be useful for example is std::unique_ptr, that is a class that
> will take ownership of a pointer and delete it when it goes out of scope.
>
> That's really useful in poppler where we have lots of
>
> if (!foo) { error; return; }
>
> where we randomly forget to delete stuff.
Indeed.
> See the patch Vincent proposed to fix the leak of colorMap in https://
> bugs.freedesktop.org/attachment.cgi?id=124163
>
> It's tricky and noone guarantees it will not break next time we introduce
> another check somewhere.
>
> What do you think?
I'm totally in favor of using C++ 11. We are no longer merging xpdf
patches, and even when we do that we do it manually, so I think we can
stop worring about diverging too much from xpdf original code.
> Cheers,
> Albert
> _______________________________________________
> poppler mailing list
> [email protected]
> https://lists.freedesktop.org/mailman/listinfo/poppler
--
Carlos Garcia Campos
PGP key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x523E6462
signature.asc
Description: PGP signature
_______________________________________________ poppler mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/poppler
