Please help. - Minix

This is a discussion on Please help. - Minix ; I open the "minix/src/lib/stdio/putc.c", the content is : --------------------------------------------------------- #include int (putc)(int c, FILE *stream) { return putc(c, stream); } --------------------------------------------------------- I cant understand it. Is it recursion? where the putc() is defined on earth? please help! thanks!...

+ Reply to Thread
Results 1 to 6 of 6

Thread: Please help.

  1. Please help.

    I open the "minix/src/lib/stdio/putc.c", the content is :
    ---------------------------------------------------------
    #include

    int
    (putc)(int c, FILE *stream)
    {
    return putc(c, stream);
    }
    ---------------------------------------------------------

    I cant understand it. Is it recursion? where the putc() is defined on
    earth?

    please help! thanks!


  2. Re: Please help.

    Hey, no it is not a recursion. The statement return putc(c, stream);
    expands a macro defined in the file /usr/src/include/stdio.h


  3. Re: Please help.

    Soni , thank you very much .
    I have another question that is why the function "putc " have a pair of
    brackets.
    It is used to distinguish the macro putc.


  4. Re: Please help.

    Soni , thank you very much .
    I have another question that is why the function "putc " have a pair of
    brackets.
    It is used to distinguish the macro putc.


  5. Re: Please help.

    Thanks, Soni.
    I have another question,why the function "putc " have a pair of
    brackets?
    Is it used to distinguish the macro putc?


  6. Re: Please help.

    Hey, Have a look at this page.....

    http://listserv.nodak.edu/cgi-bin/wa...ix-l&D=0&P=775


+ Reply to Thread