refactor(kernel): remove 'foreach' macro

Signed-off-by: EnderIce2 <enderice2@protonmail.com>
This commit is contained in:
2025-03-29 22:43:07 +00:00
parent 93d897e95c
commit 8d71ed0ad5
42 changed files with 112 additions and 119 deletions

View File

@ -35,7 +35,7 @@ void cmd_modinfo(const char *args)
if (drivers.find(id) == drivers.end())
{
bool found = false;
foreach (auto var in drivers)
for (auto var : drivers)
{
if (strcmp(var.second.Name, args) == 0)
{
@ -70,7 +70,7 @@ void cmd_modinfo(const char *args)
printf(" Path: %s\n", drv.Path.c_str());
printf(" Used Memory: %ld KiB\n", TO_KiB(drv.vma->GetAllocatedMemorySize()));
printf(" Used IRQs:%s\n", drv.InterruptHandlers->empty() ? " none" : "");
foreach (auto var in *drv.InterruptHandlers)
for (auto var : *drv.InterruptHandlers)
{
printf(" IRQ%-2d: %#lx\n",
var.first, (uintptr_t)var.second);