function pointer support added