|
-
Jan 4th, 2019, 05:17 AM
#11
Re: Clearing array is fast in VB5 but very slow in VB6
 Originally Posted by tubus
if you use LONG instead of CURRENCY, then the first call of PerformCount changes the value of the previously with PerformFreq assigned timeFreq
How on earth could this be ???
Stack layout.
Local variables are allocated on the stack and Long variables are 4 bytes each while Currency variables are 8 bytes.
Passing the address of the first Long var to an API that outputs 8 bytes at this address effectively overwrites the second Long var.
cheers,
</wqw>
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|