detecting cycles at function definitions