[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [CPROG] Andre mystiske ting med den nye c



Hej igen.
Det er såmen kun en warning, og jeg ville finde den på sin plads fra c++
compileren, men ikke fra rå c. Jeg kunne da bare kalde den int, men så
bør jeg også huske at lave en exit med en kode alle steder.... Jeg har
bare brugt void main(...) i mange år, når jeg ikke skulle bruge en
exit-kode til andet. 13 år med c giver sikkert dumme vaner..........

Søren

Mads Bondo Dydensborg wrote:
> 
> On 2 Feb 2001, Anders Melchiorsen wrote:
> 
> > "Søren H. Sørensen" <sslug@sslug> skrev:
> >
> > > Er der nogen der kan forklare den???
> >
> > main() skal, som det altid har været tilfældet, returnere int. Både i
> > C og i C++. Og "sådan er det bare" er nok den bedste grund. Men det er
> > det altså.
> 
> Uden at vide for meget om det, mener jeg at det er i 1999 revisionen af C,
> at det blev et krav, at alle typer skulle angives. Det med at noget uden
> typer har typen int, er således blevet droppet.
> 
> For du en warning eller en fejl? Jeg ville have troet at man med -Wall
> ville have fået warning om dette i årevis?
> 
> Mads
> 
> --
> Mads Bondo Dydensborg.                               sslug@sslug
> Smoking kills. If you're killed, you've lost a very important part of your
> life.
>             - Brooke Shields, during an interview to become spokesperson for a
>                                                federal anti-smoking campaign.


 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:08 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *