r220695 - Start adding the infrastructure for handling TypoExprs.

Kaelyn Takata rikka at google.com
Mon Oct 27 14:46:24 PDT 2014


Yes, the patch seems reasonable. I take it just defining the move
constructor and assignment operator as default (e.g.
"TypoExprState(TypoExprState&& other) = default;" isn't sufficient to make
MSVC happy?

On Mon, Oct 27, 2014 at 2:32 PM, Hans Wennborg <hans at chromium.org> wrote:

> On Mon, Oct 27, 2014 at 11:07 AM, Kaelyn Takata <rikka at google.com> wrote:
> > Author: rikka
> > Date: Mon Oct 27 13:07:37 2014
> > New Revision: 220695
> >
> > URL: http://llvm.org/viewvc/llvm-project?rev=220695&view=rev
> > Log:
> > Start adding the infrastructure for handling TypoExprs.
>
> The Windows bots are confused about this, e.g.:
>
> http://bb.pgr.jp/builders/ninja-clang-i686-msc17-R/builds/11221/steps/build_clang_tools/logs/stdio
>
> [...]
>
> > +  struct TypoExprState {
> > +    std::unique_ptr<TypoCorrectionConsumer> Consumer;
>
> It seems MSVC is trying to synthesize a copy constructor for this,
> which tries to copy the unique_ptr  member and fails. When this comes
> up it's usually because the object is being moved and MSVC doesn't
> realize it should synthesize a move constructor.
>
> One way to fix this is to define the move constructor and assignment
> operator ourselves. Does the attached patch look reasonable?
>
>  - Hans
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20141027/d9204a54/attachment.html>


More information about the cfe-commits mailing list