Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
Qt Creator 6.0.2
Description
For example, I have class
class SerializableClass { public: SerializableClass(const Poco::Data::RecordSet& recordSet); //// Serializing void Save(rapidjson::Value& json, rapidjson::Document::AllocatorType& allocator) const; private: ... };
Then I left click on Save function -> Refactor -> Add Definition in source file
QtCreator creates definition in my source file but with wrong signature
void SerializableClass::Save(rapidjson::Value &json, rapidjson::GenericDocument::AllocatorType &allocator) const { }
As you can see rapidjson::Document::AllocatorType becomes rapidjson::GenericDocument::AllocatorType
Document -> GenericDocument and it's not the same types
They have typedef
typedef GenericDocument<UTF8<> > Document;
So looks like QtC ignores explicit template instantiation and works with GenericDocument as non template class.