I am getting a warning message when documenting overloaded functions.
I have an implementation class and a header class.
The header class declares two virtual functions, the second of which
overloads the first.
ClassA.h
/virtual void doSomething(int i);
virtual void doSomething(int i,int j);/
The implementation class implements each virtual function, as follows
/ClassA.cpp
void doSomething(int i) {
printf ("doSomething: %d", i);
}
void doSomething(int i,int j) {
printf ("doSomething: %d", i);
printf ("doSomething: %d", j);
}/
I need to document both doSomething functions in doxygen.
How do I do it?
I have tried documenting the .h file as follows:
*Attempt 1:*
/ClassA.h
/*!
* \fn void doSomething(int i)
* do something with i
*/
virtual void doSomething(int i);
/*!
* \fn void doSomething(int i, int j)
* do something with i and j
*/
virtual void doSomething(int i,int j);/
*Attempt 2:*
//*!
* \fn void doSomething(int i)
* do something with i
*/
virtual void doSomething(int i);
/*!
* \overload void doSomething(int i, int j)
* do something with i and j
*/
virtual void doSomething(int i,int j);/
I have also tried to document the .cpp file in the same way, with and
without documenting the .h file.
However, whichever way I try, I always get the same warning message, which
is:
ClassA.cpp: warning: no uniquely matching class member found for
void doSomething(int i)
Possible candidates:
virtual void doSomething(int i) at line 123 of file ClassA.h
virtual void doSomething(int i, int j) at line 135 of file Class.h
ClassA.cpp: warning: no uniquely matching class member found for
void doSomething(int i,int j)
Possible candidates:
virtual void doSomething(int i) at line 123 of file ClassA.h
virtual void doSomething(int i, int j) at line 135 of file Class.h
Note: Ideally I would prefer to document only the .cpp file and not the .h
file in order to resolve this problem.
--
View this message in context:
http://doxygen.10944.n7.nabble.com/Warning-message-when-documenting-overloaded-functions-tp7145.html
Sent from the Doxygen - Users mailing list archive at Nabble.com.
------------------------------------------------------------------------------
BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT
Develop your own process in accordance with the BPMN 2 standard
Learn Process modeling best practices with Bonita BPM through live exercises
http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_
source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF
_______________________________________________
Doxygen-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/doxygen-users