F
fyderniX
Heya. I have a header file that looks similar to this:
namespace mupdf {
public class Data
{
public:
typedef struct fz_stream_s fz_stream;
struct fz_stream_s
{
int refs;
int kind;
int mode;
int dead;
fz_buffer *buffer;
fz_filter *filter;
fz_stream *chain;
fz_error *error;
int file;
};
};
}
When I try to create"mupdf:ata::fz_stream fileStream;" it gives me
grief, however:
..\sandbox2.cpp(18) : error C2079: 'fileStream' uses undefined struct
'mupdf::fz_stream_s'
"fz_stream_s" clearly exists from within the "Data" class. Why is the
compiler looking for it way up in the "mupdf" namespace? What am I
doing wrong?
SigmaX
namespace mupdf {
public class Data
{
public:
typedef struct fz_stream_s fz_stream;
struct fz_stream_s
{
int refs;
int kind;
int mode;
int dead;
fz_buffer *buffer;
fz_filter *filter;
fz_stream *chain;
fz_error *error;
int file;
};
};
}
When I try to create"mupdf:ata::fz_stream fileStream;" it gives me
grief, however:
..\sandbox2.cpp(18) : error C2079: 'fileStream' uses undefined struct
'mupdf::fz_stream_s'
"fz_stream_s" clearly exists from within the "Data" class. Why is the
compiler looking for it way up in the "mupdf" namespace? What am I
doing wrong?
SigmaX