[llvm] r238311 - We always have an InstPrinter.

David Blaikie dblaikie at gmail.com
Wed May 27 11:28:11 PDT 2015

On Wed, May 27, 2015 at 11:25 AM, Rafael EspĂ­ndola <
rafael.espindola at gmail.com> wrote:

> > Could we take the parameter by reference instead of pointer?
> That gets into the wonderful world of TargetRegistry.h.
> The MCAsmStreamer takes ownership of this, so the natural way would be
> to pass a std::unique_ptr. But TargetRegistry.h would have to call
> std::move, and to do that it would have to know the size of the
> instprinter instead of just having a forward declaration.
> But TargetRegistry.h is in Support, so it cannot include a header from MC.
> Getting ownership of something passed by reference would be even more
> confusing IMHO.

Ah, right - I think I remember trying to unique_ptrify this before... :/ I
should leave more breadcrumbs/comments.

> Cheers,
> Rafael
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150527/b1bf1d40/attachment.html>

More information about the llvm-commits mailing list