function, except its C based..