Wishes for MQL5 - page 88

 

Will MetaLang understand that int a(), int a(int var), bool a() and double a() are different functions?

 
GVladimir >> :

Will MetaLang understand that int a(), int a(int var), bool a() and double a() are different functions?

Yes.

 
Svinozavr писал(а) >>

They can. Clearly they can. I just don't see what that has to do with my question on the timeline and the answer to it.

It has everything to do with it. This is a clarification. Scripts and Expert Advisors can manage charts and graphical objects as they wish. But custom indicators cannot.

 
Rosh >> :

Yes.

? In C++ there is no return value overloading. Will there be one in MQL5?

 
TheXpert >> :

? In C++ there is no overloading on the return value. In MQL5 there will be ?

That's up to Slava. But in my opinion, MQL5 also doesn't have overloading by the return value type.

 
TheXpert писал(а) >>

? In C++ there is no overloading on the return value. Will there be one in MQL5?

No.

 
GVladimir >> :

Will MetaLang understand that int a(), int a(int var), bool a() and double a() are different functions?

Bottom line -- functions number 1 3 and 4 will be counted as one due to the reasons mentioned above. 1 and 2 are different functions.

stringo >> :

No.

Too bad :) ...

 
TheXpert >> :

Total -- functions number 1 3 and 4 are counted as one for the reasons mentioned above. 1 and 2 are different functions.

now they are different functions, compile the code

int a()

{

return(0);

}


int a(int a)

{

return(a*2);

}


and make sure

 
GVladimir >> :

Now these are different functions, please compile the code and see this

Compiled and verified.

'a' - function already defined and has a body *.*.mq4 (230, 5)

They are the same in MQL4. But they will be different in MQL5.

 
TheXpert >> :

Compiled and verified.

'a' - function already defined and has a body *.*.mq4 (230, 5)

They are the same in MQL4. But they will be different in MQL5.

mistake in previous post NOT Different