Page 1 of 1

Strange build error

Posted: Tue Apr 27, 2010 10:45 am
by v8dave
I get the following error on build and I can't see what I am missing.

C:\nburn\include/pins.h:55: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'PinIO'

I also get this error in the main code when I try to use the PINS class.

..\touchdrv.c:335: error: 'J2' undeclared (first use in this function)

for this line:

State = J2[45];

It lookes like a missing brace etc but I can't track it down. pins.h is included.

Anyone else seen this before?

Dave...

Re: Strange build error

Posted: Tue Apr 27, 2010 11:04 am
by v8dave
Rats!! It was the file name.

It was simply a .c file so it was being treated as a C file.

Once I changed it to .cpp it compiles perfectly as C++.!

Dave...