NO

Author Topic: Strange construct in source Tcconio library.  (Read 2344 times)

belimax

  • Guest
Strange construct in source Tcconio library.
« on: March 21, 2011, 09:12:47 PM »
Hi,

The source tcconio.c contains the following line:

void tcconio_init( void ) __attribute__((constructor));

This compiles OK with LCC-WIN32 but I get this error with PellesC:

error #2001: Syntax error: expected ';' but found '__attribute__'.

My problem is that I don't understand this construct that should terminate with a ";" for me as for PellesC.

Does somebody can help me ?

Online AlexN

  • Global Moderator
  • Member
  • *****
  • Posts: 394
    • Alex's Link Sammlung
Re: Strange construct in source Tcconio library.
« Reply #1 on: March 22, 2011, 08:05:50 AM »
AFAIK lcc-win32 has some extensions from C++ and __attribute__((constructor)) sounds for me like such an extension.  ???
best regards
 Alex ;)