Skip to Main content Skip to Navigation

Deferred cleanup and error handling in C

Jens Gustedt 1 Robert Seacord 2
1 CAMUS - Compilation pour les Architectures MUlti-coeurS
Inria Nancy - Grand Est, ICube - Laboratoire des sciences de l'ingénieur, de l'informatique et de l'imagerie
Abstract : This paper introduces the implementation of a C language mechanism for error handling and deferred cleanup adapted from similar features in the Go programming language. This mechanism improves the proximity, visibility, maintainability, robustness, and security of cleanup and error handling over existing language features. This feature is under consideration for inclusion in the C Standard.The library implementation of the features described by this paper is publicly available under an Open Source License at
Document type :
Complete list of metadata
Contributor : Jens Gustedt Connect in order to contact the contributor
Submitted on : Wednesday, December 30, 2020 - 2:39:36 PM
Last modification on : Thursday, December 2, 2021 - 3:16:56 AM
Long-term archiving on: : Wednesday, March 31, 2021 - 6:22:42 PM


Files produced by the author(s)


Distributed under a Creative Commons Attribution - NonCommercial - NoDerivatives 4.0 International License


  • HAL Id : hal-03090771, version 1


Jens Gustedt, Robert Seacord. Deferred cleanup and error handling in C. [Research Report] RR-9385, Inria Nancy - Grand Est. 2020, pp.19. ⟨hal-03090771⟩



Les métriques sont temporairement indisponibles