[26] Types de base

(Une partie de C++ FAQ Lite fr, Copyright © 1991-2002, Marshall Cline, cline@parashift.com)

Traduit de l'anglais par Christophe Galerne

Les FAQs de la section [26]


[26.1] Can sizeof(char) be 2 on some machines? For example, what about double-byte characters?

[ Haut | Bas | Rechercher ]


[26.2] What are the units of sizeof?

[ Haut | Bas | Rechercher ]


[26.3] Whoa, but what about machines or compilers that support multibyte characters. Are you saying that a "character" and a char might be different?!?

[ Haut | Bas | Rechercher ]


[26.4] But, but, but what about machines where a char has more than 8 bits? Surely you're not saying a C++ byte might have more than 8 bits, are you?!?

[ Haut | Bas | Rechercher ]


[26.5] Okay, I could imagine a machine with 9-bit bytes. But surely not 16-bit bytes or 32-bit bytes, right?

[ Haut | Bas | Rechercher ]


[26.6] I'm sooooo confused. Would you please go over the rules about bytes, chars, and characters one more time?

[ Haut | Bas | Rechercher ]


[26.7] What is a "POD type"?

[ Haut | Bas | Rechercher ]


[26.8] When initializing non-static data members of built-in / intrinsic / primitive types, should I use the "initialization list" or assignment?

[ Haut | Bas | Rechercher ]


[26.9] When initializing static data members of built-in / intrinsic / primitive types, should I worry about the "static initialization order fiasco"?

[ Haut | Bas | Rechercher ]


[26.10] Can I define an operator overload that works with built-in / intrinsic / primitive types?

[ Haut | Bas | Rechercher ]


[26.11] When I delete an array of some built-in / intrinsic / primitive type, why can't I just say delete a instead of delete[] a?

[ Haut | Bas | Rechercher ]


[26.12] How can I tell if an integer is a power of two without looping?

[ Haut | Bas | Rechercher ]


E-mail Marshall Cline Ecrire à l'auteur, au traducteur, ou en savoir plus sur la traduction.
C++ FAQ Lite fr | Table des matières | Index | A propos de l'auteur | © | Téléchargez votre propre copie ]
Dernière révision Sun Apr 13 23:54:45 PDT 2003