Add support for a constraint function