avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] Progmem types compatibility


From: Dmitry
Subject: Re: [avr-libc-dev] Progmem types compatibility
Date: Tue, 10 Jan 2012 16:09:36 +1000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.17pre) Gecko/20110415 Thunderbird/3.1.10pre

Now a few of tests with prog types are placed into Avr-libc repository:
    tests/simulate/progtype-[123].c
Look about the completeness of them, please.

The problem is compatibility.  The change in 1.8.0 is too savage,
now the user program is not compiled with obscure error:
    prog_char s[] = "123";
    ==> error: expected '=', ',', ';', 'asm' or '__attribute__' before 's'

IMHO, there is no bases for such abort (in case of C source and known
GCC version, i.e. <= 4.6).  It is sufficient to put warning:
    prog_char s[] = "123";
    ==> warning: 'prog_char' is deprecated
and continue building.

IMHO, on the other hand, Avr-libc should not provide prog types with C++
under no circumstances like __PROG_TYPES_COMPAT__.  As it is known wrong
(see example at first post), the building must be rejected.

Opinions?
May be an example of prog type misbehaviour with C code?

Dmitry.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]