Hi Raphael,
2007/11/5, Raphael Neider <[EMAIL PROTECTED]>:
> Hi Alan,
>
> > The problem is not the "const" as the error message suggest, the
> > problem is the "rom" before it.
> >
> > This code works fine:
> >
> > typedef const struct _rom_desc_tsk
> > {
> > unsigned char prioinit;
> > ...
> > } rom_desc_tsk;
>
> As indeed it should according to the ANSI C specification... I just
> guessed that you had removed the rom keyword and it still did not work.
>
> > I agree with you the best way is just "typedefining" the struct and
> > using const when declaring the variable, anyway this code is not mine,
> > I want just compile it using SDCC :-D
> >
> > How can I define the "rom" word using SDCC ?
>
> Well, you could use
> #define rom /* ignored */
> or (probably semantically closer)
> #define rom __code
> prior to the declarations. The latter allocates the constant struct in
> code memory (Flash or EEPROM).
>
wow,
it solve this error!
I found much more errors, but solved everyone until now.
I just don't know how to solve this one:
PICos18.asm:50: error: Symbol not previously defined (TBLPTRU).
PICos18.asm:51: error: Symbol not previously defined (__FPFLAGS).
If I declare "#extern TBLPTRU" it solve the problema, but it will
appear at linkage stage.
> Better luck this time,
Thank you very much,
> Raphael
>
Alan
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Sdcc-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sdcc-user