Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Créer un compte
Espaces de noms
Variantes
    Affichages
    Actions

      atexit

      De cppreference.com
      <c‎ |program

      This page has been machine-translated from the English version of the wiki usingGoogle Translate.

      The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions clickhere.

      Click here for the English version of this page

       
       
      Services d'appui aux programmes
      La fin du programme
      Original:
      Program termination
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      abort
      exit
      quick_exit (C++11)
      _Exit (C++11)
      Communiquer avec l'environnement
      Original:
      Communicating with the environment
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      Signaux
      Original:
      Signals
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      Types de signaux
      Original:
      Signal types
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      SIGABRT
      SIGFPE
      SIGILL
      SIGINT
      SIGSEGV
      SIGTERM
      Non-locales sauts
      Original:
      Non-local jumps
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      setjmp
      longjmp
      Types
      Original:
      Types
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      jmp_buf
       
      Déclaré dans l'en-tête<stdlib.h>
      int atexit(void(*func)());
      Enregistre la fonction pointée parfunc d'être appelé à la cessation normale du programme (viaexit() ou au retour d'main()) .
      Original:
      Registers the function pointed to byfunc to be called on normal program termination (viaexit() or returning frommain()).
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.
      Appel de la fonction de plusieurs threads n'induit pas une race de données. La mise en œuvre doit appuyer l'homologation des fonctions32 au moins .
      Original:
      Calling the function from several threads does not induce a data race. The implementation shall support the registration of at least32 functions.
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.

      Sommaire

      [modifier]Paramètres

      func -
      pointeur vers une fonction qui sera appelée à la fin du programme normal
      Original:
      pointer to a function to be called on normal program termination
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.

      [modifier]Retourne la valeur

      0 si l'inscription réussit, valeur différente de zéro autrement .
      Original:
      0 if the registration succeeds, nonzero value otherwise.
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.

      [modifier]Exceptions

      noexcept specification:  
      noexcept
         (depuis C++11)

      [modifier]Exemple

      #include <stdlib.h>#include <stdio.h> void f1(){puts("pushed first");} void f2(){puts("pushed second");} int main(){    atexit(f1);    atexit(f2);}

      Résultat :

      pushed secondpushed first

      [modifier]Voir aussi

      enregistre une fonction qui sera appelée lors de son invocationquick_exit
      Original:
      registers a function to be called onquick_exit invocation
      The text has been machine-translated viaGoogle Translate.
      You can help to correct and verify the translation. Clickhere for instructions.

      (fonction)[edit]
      Récupérée de «https://fr.cppreference.com/mwiki/index.php?title=c/program/atexit&oldid=47333 »
      Navigation
      Boîte à outils
      • Autres langues

      [8]ページ先頭

      ©2009-2025 Movatter.jp