You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: mod.rs
    path of file: ./repos/Theseus/kernel/interrupts/src/aarch64
    
    the code of the file until where you have to start completion: use core::arch::global_asm;
use core::fmt;

use crate::EoiBehaviour;

use cortex_a::registers::*;

use tock_registers::interfaces::Writeable;
use 
    
    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        writeln!(f, "\r{:?}", self.esr_el1)?;

        if self.fault_address_valid() {
            writeln!(f, "\rFAR_EL1: {:#018x}", FAR_EL1.get() as usize)?;
        }

        writeln!(f, "\r{:?}", self.spsr_el1)?;
        writeln!(f, "\rELR_EL1: {:#018x}", self.elr_el1)?;
        writeln!(f)?;
        writeln!(f, "\rGeneral purpose register:")?;

        let alternating = |x| -> _ {
            if x % 2 == 0 { "   " } else { "\r" }
        };

        // Print two registers per line.
        for (i, reg) in self.gpr.iter().enumerate() {
            writeln!(f, "\r      x{: <2}: {: >#018x}{}", i, reg, alternating(i))?;
        }
        write!(f, "\r      lr : {:#018x}", self.lr)
    }