|
LLVM 22.0.0git
|
Base class of cleanup handler that controls recovery of resources of the given type. More...
#include "llvm/Support/CrashRecoveryContext.h"
Static Public Member Functions | |
| static Derived * | create (T *x) |
| Creates cleanup handler. | |
Protected Member Functions | |
| CrashRecoveryContextCleanupBase (CrashRecoveryContext *context, T *resource) | |
| Protected Member Functions inherited from llvm::CrashRecoveryContextCleanup | |
| CrashRecoveryContextCleanup (CrashRecoveryContext *context) | |
Protected Attributes | |
| T * | resource |
| Protected Attributes inherited from llvm::CrashRecoveryContextCleanup | |
| CrashRecoveryContext * | context = nullptr |
Additional Inherited Members | |
| Public Member Functions inherited from llvm::CrashRecoveryContextCleanup | |
| virtual | ~CrashRecoveryContextCleanup () |
| virtual void | recoverResources ()=0 |
| CrashRecoveryContext * | getContext () const |
| Public Attributes inherited from llvm::CrashRecoveryContextCleanup | |
| bool | cleanupFired = false |
Base class of cleanup handler that controls recovery of resources of the given type.
| Derived | Class that uses this class as a base. |
| T | Type of controlled resource. |
This class serves as a base for its template parameter as implied by Curiously Recurring Template Pattern.
This class factors out creation of a cleanup handler. The latter requires knowledge of the current recovery context, which is provided by this class.
Definition at line 158 of file CrashRecoveryContext.h.
|
inlineprotected |
Definition at line 161 of file CrashRecoveryContext.h.
References llvm::CrashRecoveryContextCleanup::context, llvm::CrashRecoveryContextCleanup::CrashRecoveryContext, llvm::CrashRecoveryContextCleanup::CrashRecoveryContextCleanup(), resource, and T.
|
inlinestatic |
Creates cleanup handler.
| x | Pointer to the resource recovered by this handler. |
Definition at line 169 of file CrashRecoveryContext.h.
References llvm::CrashRecoveryContextCleanup::context, llvm::CrashRecoveryContextCleanup::CrashRecoveryContext, llvm::CrashRecoveryContext::GetCurrent(), and T.
|
protected |
Definition at line 160 of file CrashRecoveryContext.h.
Referenced by CrashRecoveryContextCleanupBase().