FunctionIndex is an identifier for a function, imported, exported, or external. The space of
FunctionIndex is shared for all of these, so FunctionIndex(N) may identify exported function
#2, FunctionIndex(N + 1) may identify an internal function, and FunctionIndex(N + 2) may
identify an imported function.
FunctionPointer serves entirely as a safer way to work with function pointers than as raw u64
or usize values. It also avoids the need to write them as fn types, which cannot be freely
cast from one to another with as. If you need to call a FunctionPointer, use as_usize()
and transmute the resulting usize to a fn type with appropriate signature.