[PATCH] Fix for PR18393 - emit error when abstract type is returned or taken by value
Robert Matusewicz
matekm at gmail.com
Mon Sep 29 08:57:37 PDT 2014
>>! In D5409#4, @rsmith wrote:
> Clang doesn't do this immediately because that's not correct:
>
> struct S {
> S f();
> virtual void g() = 0;
> };
>
> We can't tell that we need to diagnose `f` until we reach the declaration
> of `g`.
Hi,
actually after applying my patch the case you presented is handled correctly. The problematic case is this one:
struct AbstractClass;
struct S {
AbstractClass f();
};
struct AbstracClass {
virtual void g() = 0;
};
This isn't catched by my patch. I will dig deeper to check where is the problem
http://reviews.llvm.org/D5409
More information about the cfe-commits
mailing list