mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:17:35 +00:00
Revert "Kernel: Switch singletons to use new Singleton class"
This reverts commit f48feae0b2
.
This commit is contained in:
parent
0addcb45b8
commit
2fd9e72264
44 changed files with 146 additions and 184 deletions
|
@ -26,25 +26,21 @@
|
|||
|
||||
#include "NullDevice.h"
|
||||
#include <AK/StdLibExtras.h>
|
||||
#include <Kernel/Singleton.h>
|
||||
|
||||
namespace Kernel {
|
||||
|
||||
static auto s_the = make_singleton<NullDevice>();
|
||||
|
||||
void NullDevice::initialize()
|
||||
{
|
||||
s_the.ensure_instance();
|
||||
}
|
||||
static NullDevice* s_the;
|
||||
|
||||
NullDevice& NullDevice::the()
|
||||
{
|
||||
ASSERT(s_the);
|
||||
return *s_the;
|
||||
}
|
||||
|
||||
NullDevice::NullDevice()
|
||||
: CharacterDevice(1, 3)
|
||||
{
|
||||
s_the = this;
|
||||
}
|
||||
|
||||
NullDevice::~NullDevice()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue