Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
114 user(s) are online (99 user(s) are browsing Forums)

Members: 0
Guests: 114

more...

Support us!

Headlines

 
  Register To Post  

"expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Just can't stay away
Just can't stay away


See User information
Hello

i get the above error for example in this function declaration (and a lot of othes that compiled wel for OS3 but not for OS4.
It could be some headers forgotten? I don't see which, or?

int lvsearch(struct fulist *fls, char *str, char *ci, char *mode)
{
register char *p, *d, *t, *u;

etc etc

}

Thanks for any suggestion

Joseph

Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Amigans Defender
Amigans Defender


See User information
@JosDuchIt

Most likely cause is that struct fulist isn't declared anywhere. Check you've included the file that does.

Chris

Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Supreme Council
Supreme Council


See User information
@JosDuchIt

Either what Chris said or you forgot to put a ";" at the end of a struct definition.

struct fulist
{
..blah blah..
};

Vacca foeda. Sum, ergo edo

Mr Bobo Cornwater
Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Just can't stay away
Just can't stay away


See User information
@orgin
Neither seem to be the cause. The error is very systematic . I don't know for sure if it is the case for all functions (eg no complaint for the main function)
This source compiled well under OS3 <ith gcc 2.95 and i m now trying to get a working source for OS4. I added the SDI headers; It must be something iforgot to do or did not know of, i think, but what?

Joseph

Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Home away from home
Home away from home


See User information
@JosDuchIt

Typedef was not declared maybe.

(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Quite a regular
Quite a regular


See User information
@JosDuchIt

I would look at the line before the function declaration. I think it doesn't recognise it as a declaration. Look for unmatched braces, etc before that function.

cheers
tony
Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Just can't stay away
Just can't stay away


See User information
@tonyw & rest of you guys,

I got rid of the 333 errors of this type by compiling with the -D__USE_INLINE__ option, which is suggested in codeportable-fr.pdf of Mathias PARNAUDEAU - mathias.p@wanadoo.fr.
An english version exists too.

The errorcount is not down much though, although the errors are much more varied.

I'll try to tackle them one by on.


Joseph

Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Quite a regular
Quite a regular


See User information
@JosDuchIt

That option is also described in the "Porting Stuff to OS4.pdf" or whatever it is called. It is in the SDK. Of course, if you are not using the OS4 SDK but some third party compiler, you miss out on the examples and help.

cheers
tony
Go to top
Re: "expected '=', ',', ';', 'asm' or '__attribute__' before '{' token " error
Just can't stay away
Just can't stay away


See User information
@tonyw

I am using the OS4 SDK. I missed the migrating guide though. Thanks for the hint.
I just read it and amkind of dizzy. The learning curve seems quite steep to me. Still: quite usefull too.

I am wondering how this interacts with the SDI headers, which looked like a good idea to include.
Looking through thes headers i note they only include two system headers.

#include <proto/alib.h>
#include <emul/emulregs.h>


I don't find these headers though. Where can they be found?

Thnals for any help


Joseph

Go to top

  Register To Post

 




Currently Active Users Viewing This Thread: 1 ( 0 members and 1 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project