[#absl-LeakCheckDisabler]
= xref:absl.adoc[absl]::LeakCheckDisabler
:relfileprefix: ../
:mrdocs:

This helper class indicates that any heap allocations done in the code block covered by the scoped object, which should be allocated on the stack, will not be reported as leaks&period; Leak check disabling will occur within the code block and any nested function calls within the code block&period;

== Synopsis

Declared in `&lt;absl&sol;debugging&sol;leak&lowbar;check&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
class LeakCheckDisabler;
----

== Description

Example&colon;

void Foo() &lcub; LeakCheckDisabler disabler&semi; &period;&period;&period; code that allocates objects whose leaks should be ignored &period;&period;&period; &rcub;

REQUIRES&colon; Destructor runs in same thread as constructor

== Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:absl/LeakCheckDisabler/2constructor-00c.adoc[`LeakCheckDisabler`]         [.small]#[constructor]#
| Constructors
| xref:absl/LeakCheckDisabler/2destructor.adoc[`&#126;LeakCheckDisabler`] [.small]#[destructor]#
| Destroys the disabler, re&hyphen;enabling leak checking for the current thread&period;
| xref:absl/LeakCheckDisabler/operator_assign.adoc[`operator&equals;`]  [.small]#[deleted]#
| Deleted copy assignment&semi; the disabler is not copyable&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
