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

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

Re: [avr-libc-dev] Please have a look at avr-libc patch #3750


From: Dmitry K.
Subject: Re: [avr-libc-dev] Please have a look at avr-libc patch #3750
Date: Mon, 5 Sep 2005 09:31:27 +1100
User-agent: KMail/1.5

On Monday 05 September 2005 06:58, Joerg Wunsch wrote:
> Patch URL:
>
> https://savannah.nongnu.org/patch/?func=detailitem&item_id=3750
>
> Almost unnoticed went that patch that has been contributed by Ted
> Roth, at a time when he had already `retired' from the project.
>
> My only concern about it is that it would constitute an API change for
> the stdio API, so all users of the current API would have to change
> their sources.  OTOH, we've always threated that API changes might
> happen in the preamble of the stdio documentation:
>
> http://www.nongnu.org/avr-libc/user-manual/group__avr__stdio.html
>
> What do people think, is this an acceptable reason for an API change?

It is possible to facilitate transition to a new variant:

   1. To change the order of arguments 'put' as:
        int (*put)(FILE *, char) --> int (*put)(char, FILE *)
   It would allow to leave the asm program 'put' without changes.
   By the way, standard functions too have 'FILE *' the second argument.

   2. To clean the specification of arguments in 'stdio.h':
        fdevopen(int (*put)(), int (*get)(), int opts __attribute__((unused)))
   It will allow to compile existing programs without changes.

It would seem to me more useful instead of 'fdevopen' another way:
   1. Standard files to have statically.
   2. To add a function for opening one file (with individual functions  
   'put(char)' and 'get()').

Dmitry.





reply via email to

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