Errors, bugs, questions - page 1588
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
You believe that
can't change the pointer, but can change the object the pointer refers to. Well, there are no such pointers in MQL5 that can't be changed. Therefore, the const modifier always refers to the objects, to which the pointer refers.
Then where do you think the constant pointer is here!
In methods f() and g() the a pointer becomes constant.
Well, there are no such pointers in MQL5 that can't be changed. Therefore, the const modifier always refers to the objects to which the pointer refers
You should not make such categorical conclusions without sufficient knowledge about the subject. MQL has constant pointers and declared them the same way as in C++.
You should not make such categorical conclusions without sufficient knowledge of the subject. Constant pointers in MQL exist and are declared the same way as in C++.
As far as I remember the developers' explanation, constancy applies to both object and pointer.
I.e. writing const T* in MQL === const T* const in C++
It was like that before, perhaps it is different now, but I doubt it.
Compilation error
Compilation error
...
It should have been like this:
It should have been like this:
Compilation error
Compilation error