TurbineXMLParser.h
#import <Foundation/Foundation.h>
@interface TurbineXMLParser : NSObject <NSXMLParserDelegate> {
...
TurbineXMLParser.m
#import "TurbineXMLParser.h"
I have just added a new class to my current project that I previously tested in a single file. When I try and build the project I get the error: error: cannot find protocol declaration for 'NSXMLParserDelegate'
I did a bit of searching and tried adding the following ...
TurbineXMLParser.h
#import <Foundation/Foundation.h>
@protocol NSXMLParserDelegate;
@interface TurbineXMLParser : NSObject <NSXMLParserDelegate> {
...
but still get the warning: warning: no definition of protocol 'NSXMLParserDelegate' is found
any help would be much appreciated
.
.
.
EDIT_002:
Removing <NSXMLParserDelegate>
from the @interface did work, but I am curious as to why, am I getting mixed up & muddled? I was under the impression that the delegate object must adopt the NSXMLParserDelegate protocol i.e. adding <NSXMLParserDelegate>
after the superclass.
I have two instances where this is working differently, the first is a project in a single command line file where If I don't add <NSXMLParserDelegate>
is warns that:
class 'TestXMLParser' does not implement the 'NSXMLParserDelegate' protocol
The second instance is where I have setup multiple *.h and *.m files (one of the classes being MyXMLParser.h, MyXMLParser.m) when I try to build the project with <NSXMLParserDelegate>
I get this error:
error: cannot find protocol declaration for 'NSXMLParserDelegate'
Remove <NSXMLParserDelegate>
and it all works fine, no errors, no warning...
gary