Errors, bugs, questions - page 2568

 
Artyom Trishkin:

(condition1 and (condition2 or condition3))

thank you

 
Aleksandr Goryachev:

thank you

The interesting thing is that the code says exactly the same thing.

 
Artyom Trishkin:

The interesting thing is that the code says exactly the same thing.

I just wanted to clarify, I wondered...

 

Starting with some build, a function is no longer exported from the library (unresolved import):

typedef void (*pOnBookEvent)(const string &symbol);

void OrderBook_Init(pOnBookEvent ptr, const string folder, const bool common, const int offset) export

This is due to a parameter defined by typedef. If it is removed, the export starts working. How and what did MQ change? Probably something with typedefs? It turns out that when building the library in the previous build, the parameter's signature was one, but when compiling the EA that uses the library in the new build, the signature is different.

To clarify, the change occurred between 2007 and 2085 builds. A search through release notes didn't yield an answer.

 
Vict:

0x20

Is it possible to do something like this in this example?
That is, initialize a numeric char array with an empty value, not zero.

char Arr[];
ArrayResize(Arr, 5);
ArrayInitialize(Arr, '\0');
   
for(int i=0; i<5; i++)
   Print(Arr[i]);
 
Roman:

Is it possible to do something like this in this example?
That is, initialize a numeric char array with an empty value, not zero.

I don't see why not
 
Vict:
I don't see any barriers.

There is a barrier.

ArrayInitialize(Arr, ' ');

Initialized with number 32
As far as I understood, there is no empty value for a char character other than '\0'.
But this char initializes the array with zeroes.
The question was, is it possible to initialize with an empty value, not zero.

 
Roman:

There is a barrier.

Initialized with number 32
As far as I understand, there is no empty value for a char character other than '\0'.
But this char initializes the array with zeroes.
The question was, is it possible to initialize with an empty value, not zero.

Look. When you declare array char a[100], physically it means that 100 bytes were allocated on the stack, that's it, they are there and they have values from 0x0 to 0xff
 
Vladimir Simakov:
Look. When you declare char a[100] array, physically it means that 100 bytes are allocated on the stack, that's it, they are there and they have values from 0x0 to 0xff

Yes, and it contains rubbish.

char a[100];
   
for(int i=0; i<100; i++)
   Print(a[i]);

The question was quite different. To initialize it with an empty value, not zero. If such a thing is possible at all.
Zero is a number! An empty value as I understand it, no numbers, nothing.
But memory cells are initialized with this emptiness ))

 

MT5 Build 2145 dated 17 September 2019.

When the tester starts, it automatically disables the local network agent cluster. If it is forced on, the next time the tester is started it forcibly turns it off again.

So sick and tired of the problem that drags on for half a year when suddenly half of the agents stop accepting the job and you have to force them off and on again,

and now I have to turn on the local agents every time the tester starts up.

Reason: