some missing compatibility fns & macors
fix some typos, add a declare
add int-array for compat