On Friday, March 04, 2011 14:12:01 Jacob Carlborg wrote: > I've ported the isemail module from PHP to D and I'm now working on adding > exceptions instead of error codes. The PHP function takes an error level > parameter indicating what kind of error level you want. You can pass in a > warning and error level and possible others as well. You can also turn the > error handling completely off. If the error handling is turned off the > function will only return "true" or "false" indicating if the email > address is valid or not. > > If the error handling is on the function will return 0 if the email address > is valid or otherwise an error code indicating what the error was. > > The question I now has is: should we keep these different error levels or > should we just have a parameter indicating if the error handling is on or > off?
What kind of errors does it need to handle? If all it's doing is verifying whether a string is a valid e-mail address, how can you get errors from that? Either it's valid or it isn't. I have no idea what it could possibly be erroring out on. - Jonathan M Davis _______________________________________________ phobos mailing list [email protected] http://lists.puremagic.com/mailman/listinfo/phobos
