http://bugs.winehq.org/show_bug.cgi?id=33059
Bug #: 33059 Summary: Visual Basic 6 shows overflow error with arithmetic expressions Product: Wine Version: 1.5.24 Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: german_ant_82@yahoo.com Classification: Unclassified Regression SHA1: Visual Basic 6 shows overflow errors with arithmetic expressions that has results greather than 32767
When running a program or on the immediate window, Visual Basic 6 shows an overflow error with arithmetic expression that has results greather than 32767.
Dim a As Long a = 32768 <-- This doesn't cause any error a = 32767 + 1 <-- This one causes overflow error
The error message dialog shows: Run-time error '6': Overflow
This is not a normal behavior. Here, the arithmetic expressions are calculated with 16 bits binary numbers with a range from -32768 to 32767, but Visual Basic 6 is a 32 bits environment with integer expressions with a range from -4294967296 to 4294967295.