Function cannon can now constraint input type.