🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: fr.comp.lang.c
Article #15490

Re: conjugaison et autres exos sur les chaines [Was : Un système de conj...]

#15490
From: Antoine Leca
Date: Fri, 23 Sep 2005 12:50
40 lines
3735 bytes
En <news:433320a9$0$5377$8fcfb975@news.wanadoo.fr>, Harpo va escriure:
> J'utilise toujours NULL pour les pointeurs,

Si tu passes une constante pointeur nul � une fonction variadique (exemple
d'�cole, exece()), �crit plut�t (void*)0.


> Mon probl�me (qui ne me travaille qu'occasionnellement) �tait de
> savoir si l'assertion NULL = 0 �tait vraie.

NULL == 0 ? Oui, c'est toujours vrai:


6.3 Conversions
6.3.2 Other operands
6.3.2.3 Pointers

   [#4] Conversion of a null pointer to another pointer type yields
     a null pointer of that type. Any two null pointers shall compare
     equal.

et l'alin�a pr�c�dent que 0, dans un contexte de type pointeur, est le
/pointeur nul/. Et les diff�rentes d�finitions de NULL dans les ent�tes de
la biblioth�que standard d�crivent aussi la constante pointeur nul.

Remarque que tu peux avoir d'autres valeurs (physiquement stock�es) pour le
pointeur nul; mais elles seront dites �gales � NULL.


> Un rapide grep sur /usr/include m'a laiss� penser que NULL �tait chez
> moi d�fini comme ( (void *) 0 ) en C et ( 0 ) en C++

Un grand classique. Les deux formes sont permises en C, mais C++ n'admet pas
la premi�re forme. Certains compilateurs bi-langage choisissent la voie de
la simplicit� en uniformisant sur le secodne forme, mais pour la raison que
j'ai rappell� tout au d�but, beaucoup de compilateurs gardent la
diff�renciation.


Antoine
Technical Details
Message-ID: <dh0tm4$u86$1@shakotay.alphanet.ch>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!colt.net!newsfeed.icl.net!proxad.net!freenix!news.alphanet.ch!alphanet.ch!not-for-mail
References: <1126342327.583568.21420@g43g2000cwa.googlegroups.com> <mn.837a7d59123d924a.15512@YOURBRAnoos.fr> <432adddf$0$17220$8fcfb975@news.wanadoo.fr> <mn.84407d597cfa6e6e.15512@YOURBRAnoos.fr> <432b2a92$0$7861$8fcfb975@news.wanadoo.fr> <432c19e0$0$1710$8fcfb975@news.wanadoo.fr> <432cad90$0$27422$8fcfb975@news.wanadoo.fr> <432d1b7c$0$1743$8fcfb975@news.wanadoo.fr> <432d3117$0$1742$8fcfb975@news.wanadoo.fr> <mn.93877d590449a7bc.15512@YOURBRAnoos.fr> <432d7667$0$17248$8fcfb975@news.wanadoo.fr> <mn.94047d599f0cc076.15512@YOURBRAnoos.fr> <432da70c$0$1735$8fcfb975@news.wanadoo.fr> <432dd52f$0$622$626a14ce@news.free.fr> <mn.95687d59be8517f2.15512@YOURBRAnoos.fr> <432df189$0$2933$626a14ce@news.free.fr> <432e973a$0$1013$8fcfb975@news.wanadoo.fr> <432ec68e$0$3758$626a14ce@news.free.fr> <432eff47$0$27415$8fcfb975@news.wanadoo.fr> <mn.9ce67d59d5b1a352.15512@YOURBRAnoos.fr> <432f1360$0$1010$8fcfb975@news.wanadoo.fr> <dgokgi$lsm$1@shakotay.alphanet.ch> <433320a9$0$5377$8fcfb975@news.wanadoo.fr>

Show Full Headers
Complete Article Headers
X-Google-Thread: f9822,b21b26167a936e28
X-Google-Attributes: gidf9822,public
X-Google-Language: FRENCH,ASCII
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!colt.net!newsfeed.icl.net!proxad.net!freenix!news.alphanet.ch!alphanet.ch!not-for-mail
From: "Antoine Leca" <root@localhost.invalid>
Newsgroups: fr.comp.lang.c
Subject: Re: conjugaison et autres exos sur les chaines [Was : Un système de conj...]
Date: Fri, 23 Sep 2005 14:50:11 +0200
Organization: Posted through ALPHANET (http://www.alphanet.ch/)
Lines: 41
Sender: antoinel@143.red-217-127-250.staticip.rima-tde.net
Message-ID: <dh0tm4$u86$1@shakotay.alphanet.ch>
References: <1126342327.583568.21420@g43g2000cwa.googlegroups.com>   <mn.837a7d59123d924a.15512@YOURBRAnoos.fr> <432adddf$0$17220$8fcfb975@news.wanadoo.fr> <mn.84407d597cfa6e6e.15512@YOURBRAnoos.fr> <432b2a92$0$7861$8fcfb975@news.wanadoo.fr> <432c19e0$0$1710$8fcfb975@news.wanadoo.fr> <432cad90$0$27422$8fcfb975@news.wanadoo.fr> <432d1b7c$0$1743$8fcfb975@news.wanadoo.fr> <432d3117$0$1742$8fcfb975@news.wanadoo.fr> <mn.93877d590449a7bc.15512@YOURBRAnoos.fr> <432d7667$0$17248$8fcfb975@news.wanadoo.fr> <mn.94047d599f0cc076.15512@YOURBRAnoos.fr> <432da70c$0$1735$8fcfb975@news.wanadoo.fr> <432dd52f$0$622$626a14ce@news.free.fr> <mn.95687d59be8517f2.15512@YOURBRAnoos.fr> <432df189$0$2933$626a14ce@news.free.fr> <432e973a$0$1013$8fcfb975@news.wanadoo.fr> <432ec68e$0$3758$626a14ce@news.free.fr> <432eff47$0$27415$8fcfb975@news.wanadoo.fr> <mn.9ce67d59d5b1a352.15512@YOURBRAnoos.fr> <432f1360$0$1010$8fcfb975@news.wanadoo.fr> <dgokgi$lsm$1@shakotay.alphanet.ch> <433320a9$0$5377$8fcfb975@news.wanadoo.fr>
NNTP-Posting-Host: 143.red-217-127-250.staticip.rima-tde.net
Mime-Version: 1.0
Content-Type: text/plain;
 charset="iso-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: shakotay.alphanet.ch 1127479812 30982 217.127.250.143 (23 Sep 2005 12:50:12 GMT)
X-Complaints-To: usenet@alphanet.ch
NNTP-Posting-Date: Fri, 23 Sep 2005 12:50:12 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1506
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506