Re: Instruments runs forever
Re: Instruments runs forever
- Subject: Re: Instruments runs forever
- From: Jack Repenning <email@hidden>
- Date: Mon, 5 Jan 2009 15:13:32 -0800
On Dec 26, 2008, at 2:23 PM, Steve Wetzel wrote:
I am running a very small program and when I run with instruments it
runs forever. The program is:
// main.m
#import <Cocoa/Cocoa.h>
#import "Fraction.h"
int main(int argc, char *argv[])
{
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
int i = 1;
Fraction *f = [[Fraction alloc] init];
[f setNumerator:i];
[f setDenominator:i];
[pool release];
}
I have synthesized the properties in my Fraction class.
When I have run instruments in the past it always would stop. Right
now this program is running in instruments for over 4 minutes. What
is wrong?
Does your Fraction class at any time attempt to compute the float/
double value of the fraction? In particular, might it be trying that
after you've setNumerator but before you've setDenominator? Might
there be a zero denominator? Might your code be inflooping on this
undefined division?
-==-
Jack Repenning
email@hidden
Project Owner
SCPlugin
http://scplugin.tigris.org
"Subversion for the rest of OS X"
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden