cv (<div class="t-tr-text">const-volatilità<div class="t-tr-dropdown"><div><div><div class="t-tr-dropdown-arrow-border"></div><div class="t-tr-dropdown-arrow"></div><div class="t-tr-dropdown-h">Original:</div><div class="t-tr-dropdown-orig">const-volatility</div><div class="t-tr-dropdown-notes">The text has been machine-translated via [http://translate.google.com Google Translate].<br/> You can help to correct and verify the translation. Click [http://en.cppreference.com/w/Cppreference:MachineTranslations here] for instructions.</div></div></div></div></div>) specifiers

Da cppreference.com.
< cpp‎ | language

 
 
Linguaggio C + +
Temi generali
Original:
General topics
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Controllo del flusso
Original:
Flow control
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Dichiarazioni esecuzione condizionale
Original:
Conditional execution statements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Iterazione dichiarazioni
Original:
Iteration statements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Vai dichiarazioni
Original:
Jump statements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Funzioni
Original:
Functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
dichiarazione di funzione
lambda funzione dichiarazione
funzione di modello
specificatore inline
eccezioni specifiche(deprecato)
noexcept specificatore(C++11)
Eccezioni
Original:
Exceptions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Spazi dei nomi
Original:
Namespaces
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Tipi
Original:
Types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
decltype specifier(C++11)
Specifiers
Original:
Specifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
cv specificatori
Durata di stoccaggio specificatori
constexpr specificatore(C++11)
specificatore auto(C++11)
alignas specificatore(C++11)
Inizializzazione
Original:
Initialization
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Letterali
Original:
Literals
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Espressioni
Original:
Expressions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
rappresentazioni alternative
Utilities
Original:
Utilities
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Tipi
Original:
Types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
typedef declaration
Tipo alias dichiarazione(C++11)
attributi(C++11)
Lancia
Original:
Casts
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
conversioni implicite
const_cast conversion
static_cast conversion
dynamic_cast conversion
reinterpret_cast conversion
Fusione C-stile e funzionale
Occupazione della memoria
Original:
Memory allocation
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Classi
Original:
Classes
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Specifiche per una classe di funzioni proprietà
Original:
Class-specific function properties
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Funzioni membro speciali
Original:
Special member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Modelli
Original:
Templates
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
classe template
funzione di modello
modello di specializzazione
parametri confezioni(C++11)
Varie
Original:
Miscellaneous
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Montaggio in linea
 
  • const - definisce che il tipo è costante.
    Original:
    const - defines that the type is constant.
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • volatile - definisce che il tipo è volatili.
    Original:
    volatile - defines that the type is volatile.
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • mutable - definisce che un membro di una classe non influisce sullo stato visibile all'esterno della classe. mutable membri possono essere modificati in classi' costante, che è constness' è essenzialmente ignorato per il membro particolare.
    Original:
    mutable - defines that a member of a class does not affect the externally visible state of the class. mutable members can be modified in constant classes, that is constness is essentially ignored for the particular member.
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.

[modifica]Spiegazione

Nota: cv-qualificazioni </ b> e <b> cv-specificatori di </ b> (elenco) non sono la stessa cosa thing.
il CV-qualificazioni sono proprietà di un tipo, mentre cv-specificatori sono funzionalità del linguaggio per definire cv-qualificazione
Original:
Note: <b>cv-qualifiers</b> and <b>cv-specifiers</b> (list above) are not the same thing.
The cv-qualifiers are properties of a type whereas cv-specifiers are language feature to define cv-qualifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
</div>
Cv-qualificazioni definire due proprietà di base di un tipo: constness''' e la volatilità. Un cv-qualifer può essere uno dei seguenti: 'const volatile', 'const', 'volatile' o 'none'. const definisce che un tipo è costante, volatile definisce che il tipo è' volatile. Tipo non costante e non volatile non ha limitazioni aggiuntive, mentre costante e volatile implica quanto segue:
Original:
Cv-qualifiers define two basic properties of a type: constness and volatility. A cv-qualifer can be one of the following: 'const volatile', 'const', 'volatile' or 'none'. const defines that a type is constant, volatile defines that the type is volatile. Non-constant and non-volatile type has no additional restrictions, whereas constant and volatile imply the following:
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
  • ' 'Costante - l'oggetto non deve essere modificata. Tentativo di farlo si traduce in un comportamento indefinito. Sulla maggior parte dei compilatori è errore di compilazione.
    Original:
    constant - the object shall not be modified. Attempt to do so results in undefined behavior. On most compilers it is compile-time error.
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • ' 'Volatili - l'oggetto può essere modificato con mezzi non rilevabili dal compilatore, e quindi alcune ottimizzazioni del compilatore deve essere disabilitato.
    Original:
    volatile - the object can be modified by means not detectable by the compiler and thus some compiler optimizations must be disabled.
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
C'è ordinamento parziale di cv-qualificazione per ordine di crescenti restrizioni. Il tipo può essere detto più o meno cv-qualificato allora:
Original:
There is partial ordering of cv-qualifiers by the order of increasing restrictions. The type can be said more or less cv-qualified then:
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
  • Qualificato <const
    Original:
    unqualified < const
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • Qualificato <volatile
    Original:
    unqualified < volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • Qualificato <const volatile
    Original:
    unqualified < const volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • const < const volatile
  • volatile < const volatile
Qualsiasi cv-qualificazione fanno parte della definizione del tipo, quindi con diversi tipi di cv-qualifiche sono sempre diversi tipi. Pertanto fusione è necessaria per abbinare i tipi quando si assegnano le variabili, le funzioni di chiamata, ecc Solo casting per più cv qualificati tipo viene eseguita automaticamente come parte del <div class="t-tr-text"> conversioni implicite
Original:
implicit conversions
The text has been machine-translated via [http://translate.google.com Google Translate].
You can help to correct and verify the translation. Click [http://en.cppreference.com/w/Cppreference:MachineTranslations here] for instructions.
. In particolare, le conversioni sono consentiti i seguenti:
Original:
Any cv-qualifiers are part of the type definition, hence types with different cv-qualifications are always different types. Therefore casting is needed to match types when assigning variables, calling functions, etc. Only casting to more cv-qualified type is done automatically as part of
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
  • Tipo qualificato può essere convertito const
    Original:
    unqualified type can be converted to const
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • Tipo qualificato può essere convertito volatile
    Original:
    unqualified type can be converted to volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • Tipo qualificato può essere convertito const volatile
    Original:
    unqualified type can be converted to const volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • const tipo può essere convertito const volatile
    Original:
    const type can be converted to const volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
  • volatile tipo può essere convertito const volatile
    Original:
    volatile type can be converted to const volatile
    The text has been machine-translated via Google Translate.
    You can help to correct and verify the translation. Click here for instructions.
Per convertire in un meno cv qualificati tipo, const_cast deve essere utilizzato.
Original:
To convert to a less cv-qualified type, const_cast must be used.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[modifica]Parole chiave

const, volatile, mutable

[modifica]Esempio

close