MQL5 namespace query

 

So, I have a code in c++, and a similar version in MQL. The basic idea is, 'I have a variable declared inside a namespace, then declared in the global namespace'.

Both variables have similar identifiers. C++ code compiles and works fine, MQL's doesn't. So I'm wondering, what's the use of a namespace that doesn't serve it's purpose?

PS: I singled it out since it's a source of a bug in my code. Only to find out that apart from it's name, it doesn't work as it's C++ cousin.

 
Anonymous3 Geek:

So, I have a code in c++, and a similar version in MQL. The basic idea is, 'I have a variable declared inside a namespace, then declared in the global namespace'.

Both variables have similar identifiers. C++ code compiles and works fine, MQL's doesn't. So I'm wondering, what's the use of a namespace that doesn't serve it's purpose?

PS: I singled it out since it's a source of a bug in my code. Only to find out that apart from it's name, it doesn't work as it's C++ cousin.

MQL is trying, but it clearly needs a lot of house-keeping.
 
Anonymous3 Geek:
MQL is trying, but it clearly needs a lot of house-keeping.
Sure. I got tired of 'deaf ears'. Nowadays, I sit silently with 'my bugs', currently clocking around 12. It's a pity.
Reason: