Problem with __attribute__



 DEVELOP > c-Plus-Plus > Problem with __attribute__

LINK TO THIS PAGE  


rating :  0   |  0


  Page 1 of 1

1

 
Topic: DEVELOP > c-Plus-Plus
User: "Krzysztof Kolago"
Date: 19 Nov 2003 11:11:07 AM
Object: Problem with __attribute__
Hello!
I've download some header files from Internet and I've tried to use them
in my program, but Borland C++ Builder is stopping, when it reach this
structure:
struct fann_neuron
{
fann_type *weights;
struct fann_neuron **connected_neurons;
unsigned int num_connections;
fann_type value;
}__attribute__((packed));
On the last line of this structure Builder wrote that there - before
"packed" word - ")" was expected. How should I modificate header file, if I
want to compile my program with success? Example programs' sources are
stopping on the same line.
Chris
.

User: "Victor Bazarov"

Title: Re: Problem with __attribute__ 19 Nov 2003 12:18:14 PM
"Krzysztof Kolago" <krzysztof.kolago@wp.pl> wrote...

I've download some header files from Internet and I've tried to use

them

in my program, but Borland C++ Builder is stopping, when it reach this
structure:

struct fann_neuron
{
fann_type *weights;
struct fann_neuron **connected_neurons;
unsigned int num_connections;
fann_type value;
}__attribute__((packed));

On the last line of this structure Builder wrote that there - before
"packed" word - ")" was expected. How should I modificate header file, if

I

want to compile my program with success? Example programs' sources are
stopping on the same line.

Remove everything between the closing '}' and the ';'. The
__attribute__ macro (my guess) is not standard C++. Probably
the author of the code used a compiler that had that extension
and you use one that doesn't.
Victor
.


  Page 1 of 1

1

 


Related Articles
 

NEWER

pg.1232     pg.940     pg.716     pg.544     pg.412     pg.311     pg.234     pg.175     pg.130     pg.96     pg.70     pg.50     pg.35     pg.24     pg.16     pg.10     pg.6     pg.3     pg.1

OLDER