Pavel Sanda wrote:
Try putting both of these variables in an anonymous namespace.
hm, dont understand why this should help.
Same variable in the same namespace. That's what causes the conflict.
yes.
Anonymous namespace, I think, has file scope.
but thats where i dont follow you. to have two definitions of any variable in
one translation unit is invalid in C++.
Right, all files are included in the same file with monolithic builds so
the anonymous namespace will not solve Pavel's problem.
why dont we put it in header Abdel ?
I just put them inside the functions. This should solve your problem.
Abdel.