Page 1 of 1

string swap bug in QB4.5

Posted: Sat Feb 06, 2021 9:21 pm
by mikefromca
I noticed a rather strange QB bug that I can be able to reproduce. It affects QB 4.5 but not QuickBasic 1.1

This is the code that can successfully reproduce it every single time:

Code: Select all

type a
b as string * 6
c as string * 6
end type
dim d as a
swap d.b,d.c
And I can tell the problem is down to trying to exchange 2 6-byte string values with swap, because I introduced the command into another one of my programs and when i tried running it, the message at the bottom left was stuck on "binding" and sometimes the screen would either freeze up, or I get booted back to the DOS prompt without the IDE screen being erased first.