Syntax error before '{' token when declaring a class in cpp standards
I have declared a header file which is giving Syntax error before '{' token. I'm using Objective-C++, so the syntax of the header will be in cpp standards. Below is the header declaration.
#import <cocoa/cocoa.h>
#import <curl/curl.h>
class AUHttpConnection
{
private:
CURL *m_pHandle;
};
I'm not aware of all the things to be taken care while working in Mac, so I have posted this query. Any Options to be used while using Obj开发者_高级运维ective-C++?
What is the extension of the source that include the header file ? In order to be processed as an Objective-C++ source file, you have to use the "mm" extension.
Sorry for wastin your time....
Mistake was from my part.I was importing header file with cpp standards to main.m file... So i was facing this problem.
Things to be taken care...
精彩评论