For extern variable:
ex: extern QList mylist;
ForUse header guards,but I constantly receive multiple definition of variable xx.
Ex:
#ifndef GLOBAL_H
........
#endif
hope it helps,
Bala
For extern variable:
ex: extern QList mylist;
ForUse header guards,but I constantly receive multiple definition of variable xx.
Ex:
#ifndef GLOBAL_H
........
#endif
hope it helps,
Bala
Using guard macro in header file is a good practice, but it will not solve the multiple definition problem/errorOriginally Posted by BalaQT
When you know how to do it then you may do it wrong.
When you don't know how to do it then it is not that you may do it wrong but you may not do it right.
Bookmarks