Re: svn: /php/php-src/trunk/ NEWS ext/intl/config.m4 ext/intl/config.w32 ext/intl/php intl.c ext/intl/spoofchecker/spoofchecker.c
ext/intl/spoofchecker/spoofchecker.h ext/intl/spoofchecker/spoofchecker class.c ext/intl/spoofchecker/...
| From: | Stas Malyshev | Date: | Thu, 13 Jan 2011 07:11:58 +0000 |
| Subject: | Re: svn: /php/php-src/trunk/ NEWS ext/intl/config.m4 ext/intl/config.w32 ext/intl/php intl.c ext/intl/spoofchecker/spoofchecker.c ext/intl/spoofchecker/spoofchecker.h ext/intl/spoofchecker/spoofchecker class.c ext/intl/spoofchecker/... |
||
| References: | 1 | Groups: | php.cvs |
| Request: | Send a blank email to php-cvs+get-64343@lists.php.net to get a copy of this message | ||
Hi!
Some of questions:
1. Why clone is not defined? uspoof_clone exists.
2.
/* {{{ proto void Spoofchecker::areConfusable( string $str1, string $str2[, int $error_code ] )
+ * Checks if a given text contains any confusable characters
+ */
It says void but code returns bool. Same with isSuspicious.
Also, is 'issued_found' a typo?
Why wouldn't this function just return the error code?
3. + if (U_FAILURE(SPOOFCHECKER_ERROR_CODE(co))) {
+ zend_throw_exception(zend_exception_get_default(TSRMLS_C), u_errorName(SPOOFCHECKER_ERROR_CODE(co)), SPOOFCHECKER_ERROR_CODE(co) TSRMLS_CC);
None of intl parts throw exceptions on errors. Please bring the code in sync with the rest of the module.
4. + SPOOFCHECKER_METHOD_FETCH_OBJECT
Please put ; at the end of the line. I know it's not required, but the line without ; at the end makes the code less readable - each time you look at it you think "is there a problem here?"
5. Why setAllowedLocales but no setAllowedChars?
--
Stanislav Malyshev, Software Architect
SugarCRM: http://www.sugarcrm.com/
(408)454-6900 ext. 227