fixed access violation when calling builtin functions