|
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
| Hi there, I'm relatively new to the objC language, that's why I would be very happy if you could help me. The compiler gives me the following build warning (the code compiles and I can run my app just fine, but I'm curious to know which line of code causes this behavior): "Assignment makes pointer from integer without a cast". The error occurs in the line "age = newAge"... I declared age as an int in the .h file. CODE: #import "Person.h" @implementation Person @synthesize lastName, firstName, age; -(id)initWithFirstName:(NSString *)fName name:(NSString *)lName age:(int)newAge; { if (self = [super init]) { lastName = lName; firstName = fName; age = newAge; // ERROR occurs here! } return self; } Any suggestion would be appreciated. Thanks in advance. -M |
_______________________________________________ Do not post admin requests to the list. They will be ignored. Objc-language mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
| Home | Archives | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2011 Apple Inc. All rights reserved.