Errors, bugs, questions - page 1692

 

Two sources with the same content occupy different number of bytes (twice as different).

There seems to be some unicode fiddling going on at some point.

In general, how do I make a large file to take up half as many bytes? At the same time, so that the text of the source remains unchanged.

 
fxsaber:

Two sources with the same content occupy different number of bytes (twice as different).

There seems to be some unicode fiddling going on at some point.

In general, how can I make a large file to take up half as many bytes? At the same time, so that the source text remains unchanged.

I copied contents of big file into Notepad and saved it into new file. It became half the size.

And how to make metaeditor not to create "thick"?

 
fxsaber:

And how do you make the metaeditor not create "fat" ones?

You can't. It's a new size every time.
 
fxsaber:
You would have run it first. The error is ONLY hereAll calls before that go through without problems.

This one is really weird. The pluses here are wrong in all three calls.

It's a different story.

No, it's the same. I've looked through the method calls in debugger: commented out the last call in your example, put breakpoints on both methods of the class and started debugging. The breakpoint was removed from void func(const int&) method, i.e. the compiler kicked out this method, so the ambiguity was eliminated. And if you call a function with a constant argument, the compiler evidently does not remove the method with the reference and the result is an unsolvable overload... Something like this. In any case, your code is flawed in C++.

 

Sergei Vladimirov:

In any case, your code is flawed in C++.

In mql, there is extra stuffing with references. Either way, I don't like the behaviour in the code above.

void f(const int& x)
{}

void OnStart()
{
   f(5); // ошибка
}
 
Sergei Vladimirov:

This one is really weird. There is an error in the pluses here in all three calls.

In this case, I wouldn't want there to be a change towards C++ at all.
 
Комбинатор:

In mql there are extra linking contraptions. In any case, I don't like the behaviour in the code above.

void f(const int& x)
{}

void OnStart()
{
   f(5); // ошибка
}
The error is correct here.
 
fxsaber:
In this case, I wouldn't want there to be a change towards C++ at all.

Now, that's the chorus question of the debate. I just told you "where the dog is in the hole".

The behaviour, by the way, is the same as in C++, but if we leave only the first two calls, the compiler throws out one of the functions, so the uncertainty disappears. But it's still an error, just automatically fixed by the compiler.

 
fxsaber:
The error is correct here.
Yes, but in my mind there shouldn't be one at all )
 
Sergei Vladimirov:
But it's a debatable question. :) I just answered you "where the dog is hidden".

There really is no dog there. The priority in overload can be set in the compiler, as the developers did with the first two calls.