ON ERROR wont catch it, critical errors and kills the program, thing is the file isn't even 0 bytes it 8 as you can see in the image.
but I isolated the line its not a division in the direct visual sense, its actually cause by a MOD. I was thinking strictly '/' or '\' and was looking just for those, easy to forget MOD is a division under the hood.
IF (LOC(5) MOD modd&) = 0 THEN LOCATE 17, 1: PRINT LOC(5)
that causes the error cause the file isn't 0 its 8 bytes and 8/10 is .8 and QB64 turns INT(.8) to 0 will be adding a +1 to the end of that.
PRINT "<= 250000 small run" modd&
= INT(LOF(5) / 10) '<--- thee offending 0 is produced here. IF temp1~%
= temp2~%
THEN match~&
= match~&
+ 2 ELSE nomatch~&
= nomatch~&
+ 2
so apparently MOD is treated like an integer division '\' and doesn't get the 1.#INF treatment.
Would there be anyway to change that? cause ON ERROR doesn't seem to catch before the program gets killed by the CRITICAL ERROR msg from the OS(windows anyway).