Array limitations

 

I have encountered the following compilation error:

"[" - too many arrays

I reduced the number of arrays declared as global variables it compliled ok yesterday.

Today, I added more functions to my #include file, it gives me the same error even when I regrouped some global arrays into functions as local arrays. What seems to be the limitation?

I have a big include file that contains all the common functions used in my indicators and EAs. And I conveniently include in all my programs. Is there a limitation on the number of arrays declared in a program be it global or local variables?

It is frustrating that I cannot find any limitation documentation in mt4... Can someone help?

 
Can u share the whole code? How many arrays are we talking about?
 
gordon:
Can u share the whole code? How many arrays are we talking about?


~6000 lines of codes all functions that i commonly use in my indicators/EAs in 1 big include file that I included in all my EAs/indicators/scripts.

The global arrays are not a lot, probably <100. After I changed some global arrays into function calls with local arrays, it still didnt work.

Finally, I circumvented the problem by breaking the big include file into several include files and excluded those files that i dont use in my script and it compiled.

Looks like there is a limitation on the number arrays whether globally declared or locally declared in functions?

 
williamwong:

Looks like there is a limitation on the number arrays whether globally declared or locally declared in functions?

Found an answer on the Russian forum -> https://www.mql5.com/ru/forum/112552. Use Google translate. It seems u r right and there is a limitation...

Reason: