Errors, bugs, questions - page 2326
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
there's no concept now, an object and a pointer to it are mixed up in one pile
This allows pointers to be handled as objects, which in some cases gives a simpler and clearer notation without *
and such pointers can also be used as references
And now they propose to destroy it all and return to the Stone Age for the sake of no one knows what
And now they are proposing to destroy it all and go back to the Stone Age for who knows what.
well, that's your opinion. i think exactly the opposite.
Well, that's your opinion. I think exactly the opposite.
A100:
А что конкретно Вас не устраивает? Что в MQL указатель это фактически ссылка?
actually that's not true )
While in MQL address arithmetic is meaningless and therefore not used!?
actually it's not )
smart pointers also don't have address arithmetic, but they are used for some reasonStrictly speaking, no, but in the absence of address arithmetic, an MQL pointer\writer is closer (or at least not further) to a C++ reference than a C++ pointer
And if so, the syntax must be preserved accordingly (without *)
No, there were no serious reasons.
The only justification for its absence is to take care of the fragile minds of users unfamiliar with C++.
Strictly speaking, it's not, but in the absence of address arithmetic the pointer/mQL pointer is closer (or at least not further) to a C++ reference than to a C++ pointer
And if so, the syntax should be stored accordingly (without *)
Why make it so complicated? It is enough to make . and -> equivalent, interchangeable records
Figuratively speaking.
If you make them interchangeable, you simply don't need them both.
In C++, this is possible:
The operator -> should really be added to the language, firstly for the purpose of compatibility with C++ codes and secondly to allow overloading (which is useful for smart pointers).
The dot is a universal operator in MQL.
Why hasn't MQL fixed the bug that a base class is implicitly cast to a derived class? Not even a compiler warning!