checkConstrainted wasn't able to handle regular functions