This doesn't really seem to save you much, since you're going from:
validate(IpAddr, Regex)
to validateIpAddr(Regex)
I have to admit I'm a little fuzzy on why currying is desirable so there's probably something obvious I'm missing.It's `validateIpAddr(String)`: the first argument is fixed. Suppose you have a list of strings, and you want to extract the ones that are IP addresses. Then you can just write
filter (validate ipRegex) listOfStrings
instead of filter validateIpAddr listOfStrings
where validateIpAddr string = validate ipRegex string
validate :: Regex -> String -> T
validate r s = ...
validateIpAddr :: String -> T
validateIpAddr = validate ipRegex
validateZipCode :: String -> T
validateZipCode = validate zipCodeRegex
And so on and so forth. It can reduce boilerplate, and lets you do stuff like map partially applied functions to functors.