rom: Make rom_funcs functions call function instead of returning it

This commit is contained in:
Asaf Fisher 2021-02-03 21:43:14 +02:00
parent 1744151025
commit 1848789ca3

View file

@ -35,8 +35,9 @@ macro_rules! rom_funcs {
) => {
$(
$(#[$outer])*
pub fn $name() -> extern "C" fn( $( $aname : $aty ),* ) -> $ret {
rom_table_lookup(FUNC_TABLE, *$c)
pub fn $name($( $aname:$aty ),*) -> $ret{
let func: extern "C" fn( $( $aty ),* ) -> $ret = rom_table_lookup(FUNC_TABLE, *$c);
func($( $aname ),*)
}
)*
}