How can I set a pointer to a C array in my constructor?
@implementation NSBufferedInputStream {
char *buffer;
int bufferSize;
}
- (id)initWithFileAtPath:(NSString *)path
{
self = [super initWithFileAtPath:path];
if (self) {
bufferSize = 100;
buffer = char[bufferSize]; // ERROR: Expected expression
}
}
@end