[Top][All Lists]

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

[Tinycc-devel] How TCC handlse the scope

From: Anton
Subject: [Tinycc-devel] How TCC handlse the scope
Date: Fri, 22 Jun 2007 22:51:49 +0400
User-agent: Opera Mail/9.00 (Win32)

Hi again,

   This time a have been amazed at the strange  behaviour  of
   TCC regarding the scope.

   How can a function defined in file b.c be visible from a.c
   when its declaration is lacking in header  files  included
   in a.c and in a.c itself?

   When I try to declare in a.c a function with the same name
   I get a message about the function's having  been  defined

   Is TCC supposed to work so or what?

   Listing of a.c -------------------------------------------

     main () {

   Listing of b.c -------------------------------------------
     int print(int c) {
        printf("Print: %i", c); // it should not be visible!

Thanks in advance,

reply via email to

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