error: multiple definition of `decrease_seq(int, QString)'
-
wrote on 7 Sept 2018, 18:20 last edited by A Former User 9 Jul 2018, 18:31
-
wrote on 7 Sept 2018, 18:25 last edited by
-
You'll have to give us a bit more context. What file is it in? do you have declaration/implementation?
wrote on 7 Sept 2018, 18:29 last edited by@VRonin I'm trying to make header file conrain all the common functions in my application
when i include once it goes ok but when i include it in two source files it give me multiple definition error -
@VRonin I'm trying to make header file conrain all the common functions in my application
when i include once it goes ok but when i include it in two source files it give me multiple definition error@davidlabib
Hi
It seems you have the full function in the HEADER (.h) file ?
You should have like
in .hvoid somefunc( int param ); // JUST the header of the function.
and in .cpp
void somefunc( int param ) {
..code..
}
1/4