compile error

I define a class as below:
#ifndef RAW_DEVICE

#define RAW_DEVICE

class VlanDevice
when it is compiled in qnx ide,there is one error “expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘:’ token”,why?


There must be something else in your file / project besides what you posted (like an include file or other code).

when I cut and pasted your code into a file on my QNX machine and compiled directly in QNX using qcc it compiled just fine.


I’m guessing it’s compile as a C file. What is the extention of the file?