cppclean icon indicating copy to clipboard operation
cppclean copied to clipboard

False warning of Not used forward declaration

Open drodil opened this issue 7 years ago • 2 comments

When using forward declaration and templates the cppclean gives false warning. Not sure if this is related to the using keyword or the use of template. To reproduce:

template<typename T>
class Container {
}

class Item;
using ItemContainer = Container<Item>;

drodil avatar Feb 23 '18 06:02 drodil

I have the same issue with this code in header file :

class MyFwdDeclClass;

bool myFunc(std::vector<MyFwdDeclClass>& vec);

Caerind avatar Jun 06 '19 10:06 Caerind

Same issue again when the usage is followed by & :

bool myFunc(MyFwdDeclClass& class);

Caerind avatar Jun 06 '19 11:06 Caerind