mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 04:27:45 +00:00
AK: Remove bitrotted Traits::dump() mechanism
This was only used by HashTable::dump() which I used when doing the first HashTable implementation. Removing this allows us to also remove most includes of <AK/kstdio.h>.
This commit is contained in:
parent
c8eaae3eaf
commit
6cbd72f54f
24 changed files with 3 additions and 63 deletions
|
@ -26,7 +26,6 @@
|
|||
|
||||
#include "FullDevice.h"
|
||||
#include <AK/StdLibExtras.h>
|
||||
#include <AK/kstdio.h>
|
||||
#include <LibC/errno_numbers.h>
|
||||
|
||||
FullDevice::FullDevice()
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
|
||||
#include "NullDevice.h"
|
||||
#include <AK/StdLibExtras.h>
|
||||
#include <AK/kstdio.h>
|
||||
|
||||
static NullDevice* s_the;
|
||||
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
|
||||
#include "ZeroDevice.h"
|
||||
#include <AK/StdLibExtras.h>
|
||||
#include <AK/kstdio.h>
|
||||
|
||||
ZeroDevice::ZeroDevice()
|
||||
: CharacterDevice(1, 5)
|
||||
|
|
|
@ -34,7 +34,6 @@
|
|||
#include <AK/RefPtr.h>
|
||||
#include <AK/String.h>
|
||||
#include <AK/WeakPtr.h>
|
||||
#include <AK/kstdio.h>
|
||||
#include <Kernel/Devices/BlockDevice.h>
|
||||
#include <Kernel/FileSystem/InodeIdentifier.h>
|
||||
#include <Kernel/FileSystem/InodeMetadata.h>
|
||||
|
@ -128,7 +127,6 @@ namespace AK {
|
|||
template<>
|
||||
struct Traits<InodeIdentifier> : public GenericTraits<InodeIdentifier> {
|
||||
static unsigned hash(const InodeIdentifier& inode) { return pair_int_hash(inode.fsid(), inode.index()); }
|
||||
static void dump(const InodeIdentifier& inode) { kprintf("%02u:%08u", inode.fsid(), inode.index()); }
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -79,11 +79,6 @@ struct Traits<IPv4SocketTuple> : public GenericTraits<IPv4SocketTuple> {
|
|||
auto h2 = pair_int_hash(tuple.peer_address().to_u32(), tuple.peer_port());
|
||||
return pair_int_hash(h1, h2);
|
||||
}
|
||||
|
||||
static void dump(const IPv4SocketTuple& tuple)
|
||||
{
|
||||
kprintf("%s", tuple.to_string().characters());
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -82,7 +82,6 @@ namespace AK {
|
|||
template<>
|
||||
struct Traits<MACAddress> : public GenericTraits<MACAddress> {
|
||||
static unsigned hash(const MACAddress& address) { return string_hash((const char*)&address, sizeof(address)); }
|
||||
static void dump(const MACAddress& address) { kprintf("%s", address.to_string().characters()); }
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -24,7 +24,6 @@
|
|||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include <AK/kstdio.h>
|
||||
#include <Kernel/ProcessTracer.h>
|
||||
|
||||
ProcessTracer::ProcessTracer(pid_t pid)
|
||||
|
|
|
@ -100,6 +100,8 @@ void* SharedBuffer::ref_for_process_and_get_address(Process& process)
|
|||
void SharedBuffer::share_with(pid_t peer_pid)
|
||||
{
|
||||
LOCKER(shared_buffers().lock());
|
||||
if (m_global)
|
||||
return;
|
||||
for (auto& ref : m_refs) {
|
||||
if (ref.pid == peer_pid) {
|
||||
// don't increment the reference count yet; let them get_shared_buffer it first.
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
*/
|
||||
|
||||
#include <Kernel/Process.h>
|
||||
#include <LibBareMetal/Output/kstdio.h>
|
||||
|
||||
extern "C" const char module_name[] = "TestModule";
|
||||
|
||||
|
|
|
@ -27,7 +27,6 @@
|
|||
#include "CMOS.h"
|
||||
#include "Process.h"
|
||||
#include <AK/Assertions.h>
|
||||
#include <AK/kstdio.h>
|
||||
#include <Kernel/Arch/i386/CPU.h>
|
||||
#include <Kernel/FileSystem/Inode.h>
|
||||
#include <Kernel/Multiboot.h>
|
||||
|
|
|
@ -70,7 +70,6 @@
|
|||
#include <Kernel/TTY/PTYMultiplexer.h>
|
||||
#include <Kernel/TTY/VirtualConsole.h>
|
||||
#include <Kernel/VM/MemoryManager.h>
|
||||
#include <LibBareMetal/Output/kstdio.h>
|
||||
|
||||
[[noreturn]] static void init_stage2();
|
||||
static void setup_serial_debug();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue