Errors, bugs, questions - page 2003

 
Anton Ohmat:
Can you tell me how to turn off the possible loss of data due to type conversion error?

You even have a link to a solution to the problem, which is highlighted in green on the smart site.

 
Vitaly Muzichenko:

You even got a link to a solution to the problem from a clever website, and it's highlighted in green.

Maybe you got it wrong. I want the compiler not to display this particular error to me. Or, how can I get the error to be printed in the line in php? Is there such a thing?

 
Anton Ohmat:

Maybe you've got it wrong. I want to avoid this very error from the compiler. Or how to prevent the error from being printed in a line in php. Is there such a thing?

Well, this link is where you should have read an example of explicit type conversion.

Both explicit and implicit type conversions can be used in MQL5 expressions. An explicit type conversion is written as follows:

var_1 = (тип)var_2;
 
Anton Ohmat:

Maybe they are misunderstood. I want the compiler not to display this particular error to me. Or how to prevent the error from being printed in the line in php. Is there such a thing?

Errors should not be hidden, but eliminated.

 
Vitaly Muzichenko:

Errors should not be hidden, but eliminated.


Case in point:

I have a dashboard of my own making

and there are about 20 warnings like "check the data is correct"

like "if the button doesn't draw, if the line setting doesn't work"

"non-strict compilation mode.

I've hidden them by going into variables and overwriting them at the beginning of the tick.


What's wrong with that? It's working.

(I'm talking about the optional check types)
 
Mickey Moose:

concrete example:

I have a panel of my own making

and there are about 20 warnings like "check that the data is correct"

like, "if the button doesn't draw, if the line set doesn't work"

"non-strict compilation mode.

I've hidden them by going into variables and overwriting them at the beginning of the tick.


What's wrong with that? It all works.

(I'm talking specifically about optional check types)

Today it's a warning and tomorrow with the release of a new build it's an error. This is not the right approach, if you write it, don't write it at random.

If the program works, it does not mean that there are no bugs in it.

 
Mickey Moose:

concrete example:

If you stop checking (and trying to clean up) these messages, sooner or later it will happen that one of these messages will point to a mistake you have made, and you will ignore it. It will take you a long time to find out what the problem is.
 
So, can I then disable the ability to update the thermal without my consent? Why would I want another situation where I have to rewrite part of the EA after some build is released.
 
Mickey Moose:
So, can I then disable the ability to update the thermal without my consent? Why would I want another situation where I have to rewrite some of the EAs after some build is released.

You don't have to rewrite them. They need to be written from the beginning so they don't have to be rewritten.

 
Alexey Viktorov:

They don't need to be rewritten. You have to write them from the beginning so you don't have to rewrite them.

Many people remember how some of the EAs stopped working after the next update.
Reason: