mirror of
https://github.com/NixOS/nix.git
synced 2025-12-23 09:21:09 +01:00
treewide: Follow rule of five
Good to explicitly declare things to not accidentally do twice the work by preventing that kind of misuse. This is essentially just cppcoreguidelines-special-member-functions lint in clang-tidy.
This commit is contained in:
parent
8c74aadbf7
commit
54d2268d84
10 changed files with 68 additions and 14 deletions
|
|
@ -741,6 +741,11 @@ public:
|
|||
inDebugger = true;
|
||||
}
|
||||
|
||||
DebuggerGuard(DebuggerGuard &&) = delete;
|
||||
DebuggerGuard(const DebuggerGuard &) = delete;
|
||||
DebuggerGuard & operator=(DebuggerGuard &&) = delete;
|
||||
DebuggerGuard & operator=(const DebuggerGuard &) = delete;
|
||||
|
||||
~DebuggerGuard()
|
||||
{
|
||||
inDebugger = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue