Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Stack size limit for If/Then statements?
#1
Hi All,

I'm developing a program where I am implementing a lot of if/then statements to do logic, but the way it is designed, I will have to use a lot of straight logical statements. I have tried using this through DATA statements and arrays, dimension the arrays as $'DYNAMIC, etc...so I am just going the straightforward route.

A sample line for an IF / THEN statement is just this:

IF Lookahead$ = CHR$ (0) THEN G$="XXXXXXX": PUT #2 , ,G$ : G$=""

where the line has about 3 or less multi-statements, and only if they are true. Is is simple, but there are many of them. I am already using a logic tool to automate the process, that is why I cannot do it another way. The automation is simple and straightforward, at the expense of stack space because each of the statements are automatically generated and then can be used in QB64 code.
 
The kicker is, I have about 9,786 lines that I can use successfully - anything more, I will get a C++ error.

I think it has to do with the Main() sub being limited to approximately 10,000 lines or less (9,786 exactly), but am not entirely sure.

How can I increase the number of logic statements and conditionals that are outside of arrays? Is it just the stack space, or will I have to do it another way?

What are my options with this? I have tried using CLEAR, and that won't do either. Is it possible to somehow allocate a tremendous amount of stack size at the risk of very minimal variables? Or perhaps edit and recompile a modified version of Qb64Pe source code that will work for this increasing the line numbers and limits?

Thanks,
James
Reply


Messages In This Thread
Stack size limit for If/Then statements? - by JamesAlexander - 01-28-2024, 10:59 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Recursion Limit bplus 14 2,510 10-17-2025, 07:46 PM
Last Post: a740g
  Feature Request: Limit Scope of a "Find" and "Change" hanness 5 716 06-21-2025, 11:21 PM
Last Post: SMcNeill
  Recursion limit? TerryRitchie 5 1,160 03-12-2024, 02:17 PM
Last Post: GareBear
  Can't set font size in Linux Circlotron 3 975 08-28-2022, 05:58 PM
Last Post: mnrvovrfc
  How can I change editor font size in Linux bigriverguy 1 722 06-22-2022, 06:15 PM
Last Post: cage

Forum Jump:


Users browsing this thread: 1 Guest(s)