Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Hi!
I have experienced strange problem in 64bit version of MT5 when the function is imported from the external library.
I have created a sample function in C:
double __stdcall test_double(double d)
{
return (d*1.22);
}
and declared it in MQL:
double test_double(double d);
When invoked in MQL like that:
Print ("test_double:"+test_double(100));
I got:
2010.10.11 18:12:42 double_bug (EURUSD,H1) test_double:-1.#IND
The very same code works like a charm when recompiled for an run under 32 bit MT5 platform.
It's very strange as double and float data types are standard across all platforms and do not depend on the architecture.
Later I redefined the routine to:
double __stdcall test_double(double d)
{
return (1.22);
}
And got the very same result.
Looks like a terminal bug.