updated code generation to automatically exclude any function that returns a function type or takes a function type as a parameter