[Top][All Lists]

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

[avr-libc-dev] [bug #33716] pgmspace typedefs not legal

From: Georg-Johann Lay
Subject: [avr-libc-dev] [bug #33716] pgmspace typedefs not legal
Date: Sat, 09 Jul 2011 10:25:31 +0000
User-agent: Opera/9.80 (Windows NT 5.0; U; de) Presto/2.6.30 Version/10.63

Follow-up Comment #1, bug #33716 (project avr-libc):

As Bill already wrote, attribute progmem just works by accident in avr-gcc (
and not at all in avr-g++).

It appears that
   const prog_char c = 'a';
works for C and not for C++.  However, there is *no* support for progmem in
types it in avr-gcc and there is no guarantee that it will work for any code

I highly recommend to deprecate types like prog_char:

typedef char __attribute__((progmem,deprecated)) prog_char;


typedef char __attribute__((progmem,deprecated("message"))) prog_char;

Notice that despite "progmem", "deprecated" *is* documented for types.

As the next release of avr-libc will come with bulk of poison, anyway, this
bit of deprecation won't hurt and will help users to write more robust code.



Reply to this item at:


  Nachricht geschickt von/durch Savannah

reply via email to

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