tinycc-devel
[Top][All Lists]
Advanced

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

Re: [Tinycc-devel] How TCC handlse the scope


From: Bernhard Fischer
Subject: Re: [Tinycc-devel] How TCC handlse the scope
Date: Fri, 22 Jun 2007 23:44:05 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

On Sat, Jun 23, 2007 at 01:39:28AM +0400, Anton wrote:
>   Rob:
>     Actually, this is fairly straightforward C. If you use a
>     function that there hasn't been a prototype for yet, you
>     get the default prototype for that function.
>
>   Hmmm. So is there a way to make part of a unit's functions
>   invisible from the outside (== not to "export"  them)?  In
>   Pascal you could access a function only  if  it  had  been
>   explicitly imported from another unit  (uses...),  wherein
>   it had been explicitly exported (through declaring  it  in
>   the interface section). In C everything  is  visible  from
>   anywhere (I mean functions not variables which do  require
>   an extern statement).
>
>   Is there a way to follow the right structured programming,
>   exporting only  the interface  part and leaving  the rest
>   private?

This is not really related to tcc but is a generic question about C. I
suggest you look for the keyword static in your copy of the spec for the
gory details.

HTH,




reply via email to

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