gcc v3.0.1 vs gcc v2.95.3 -- KDE 2.2.1

Christos Ricudis ricudis at paiko.gr
Fri Nov 30 01:16:29 EET 2001


Hello V13!

  On 29 Nov 01, V13 wrote to All with subject "Re: gcc v3.0.1 vs gcc v2.95.3 --
KDE 2.2.1":

 V> $ cat a.cc
 V> int main(char *p)
 V> {
 V> }

 V> void main(int n)
 V> {
 V> }

 V> $ g++ a.cc
 V> a.cc:6: `main' must return `int'
 V> a.cc: In function `int main(...)':
 V> a.cc:6: declaration of C function `int main(...)' conflicts with
 V> a.cc:2: previous declaration `int main(char*)' here

 V> Gia prospathise na moy eksigiseis to parapano.
 V> Den tha eprepe na ginei compile? Kai ektos aytoy, ante bgale
 V> akri apo to error message, poy leei oti yparxoyn 2 "int main()"

 V> An eprepe na einai lathos, tote aplos eprepe na leei oti den
 V> yparxei h "int main()" (otan exei dilothi mono "void main()" kai
 V> oxi oti 'prepei na einai etsi'

Prwth fora blepw an8rwpo na xrhsimopoiei C++ gia na anadeiksei thn elleipsh
polymorfismou sth C ws bug. 

--
Christos Ricudis

If god us wanted to RPN use, he would us made this way talk



More information about the Linux-greek-users mailing list