Nick Rogers wrote:
NSTimeInterval etaDouble = interval * ((totalBlocks -
blockCount) / blockCount); // * debugger doesn't list this
variable, mouse shows a pop up saying "variable optimized away by
compiler"
int eta = (int)etaDouble; // value is 0 here instead of something
What are the types of totalBlocks and blockCount?
Have you confirmed, say by NSLog'ing it, that the value of etaDouble
has a non-zero integer part?
If you NSLog etaDouble, or use it in any way that affects anything
outside the 'for' block, it won't be optimized away.
-- GG
_______________________________________________
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to arch...@mail-archive.com