Errors, bugs, questions - page 494

 
marketeer:

As a summary, I'll repeat the idea I once expressed: the task of the platform, which is MT, is to protect the user (the programmer) from possible "rake" as much as possible.

I strongly and categorically object. The platform has no such task. I always react very frowningly to leftist attempts to shield me from "extra" bars, from tick history, from writing files wherever I want, from testing against my own quotes and other such concerns.

I tolerate it only because I hope it has some business reasons, and it's not my business to tell MQ how to do business.

Although I have nothing against this :

I.e. another #property could have been introduced to indicate whether buffers should be initialised automatically.
I have nothing against it, because such a solution increases possibilities, not limits them.
 
MetaDriver:

I am strongly and categorically against it. The platform has no such task. I always react very frowningly to leftist attempts to shield me from "extra" bars, from tick history, from writing files wherever I want, from testing against my own quotes and other such concerns.

I didn't suggest restricting anything, just reducing error sources and leaving behavioural compatibility with MT4, at least optionally.

The platform has such a task, otherwise let's blaspheme, for example, rubbish collector in java and other routine stuff, which is easier (and RIGHT) to do once inside the platform, than to force each programmer to do in his own way, with bugs.

 
marketeer:

I wasn't suggesting to limit anything, just to reduce error sources and leave compatibility in behaviour with MT4, at least optionally.

Otherwise, let's blaspheme, for example, java rubbish collector and other routine features, which are easier (and RIGHT) to do once inside the platform, than to make every programmer do in his own way, with bugs.

I don't want to get into religious arguments about "right" and "wrong", except to say that we may go as far as performance of MT4 in our pursuit of compatibility. Which I wouldn't like to do.
 
MetaDriver:
I don't want to get into a religious debate about "right" and "wrong", but I would like to point out that in the pursuit of compatibility it is possible to get as far as MT4 performance. Which I wouldn't like to do.
Well, that's as always - it depends on the execution. If not to deviate from a concrete example, it seems obvious, that the initialization of the buffer "manually" (which is now done by many developers, and what's more - the non-initialization is called a custom indicator error by MC representatives), being moved into kernel (and enabled optionally) would not affect negatively on the performance.
 
marketeer:

I.e. another #property could be entered to indicate whether buffers should be initialised automatically.

I agree, sometimes that might be useful. But only sometimes.
 

Renat:

Recursion is usually easy to catch - it depends directly on the volume of local variables, and there are exceptionally few such places in a program.

I do not know, purely intuitively determined (assumed) that it was the processing of the tick that looped. And the "mischief" came after about 10 minutes of thorough digging in the code and comparing old copies of the Expert Advisor with a copy into which the changes were introduced.

If the preprocessing will significantly complicate the compiler (the arguments of MetaDriver seemed very convincing), I would like to get more accurate information about the place where the problem arose.

 
Interesting:

I don't know, purely intuitively determined (assumed) that it was the tick processing that was looped. And that "mischief" came after about 10 minutes of thorough digging in the code and comparing old copies of Expert Advisor with the copy where the changes were made.

Digging around a bit deeply enlightens the mind. "What would we do if daddy didn't drink? But this way, we give away the bottles and use the money to buy bread".
 
stringo:
A thorough dig is very enlightening to the mind. "What would we do if daddy didn't drink? But this way, we turn in the bottles and use the money to buy bread."
I see the logic... :)
 

Comrades, are there any plans to improve the Bars() function? It seems to me that it is not quite adequate. It may give out 0, in which case it is not clear whether there are really no bars or an error, GetLastError() does not notice it either, it makes us invent unnecessary and slowing down tricks

Документация по MQL5: Доступ к таймсериям и индикаторам / Bars
Документация по MQL5: Доступ к таймсериям и индикаторам / Bars
  • www.mql5.com
Доступ к таймсериям и индикаторам / Bars - Документация по MQL5
 

And another question, for example the following situation:

I need 100 bars from the timeseries High on the hour chart. What will be more efficient - to copy 100 bars from the Expert Advisor or get them from the array passed to the indicator? I.e., the question is if I attach the indicator to the chart, will it copy the bars that I will not use? (Is it possible to find out the time spent on theexecution of a program using MQL tools?

Reason: