]> granicus.if.org Git - php/commitdiff
Fix a few comments
authorMáté Kocsis <kocsismate@woohoolabs.com>
Mon, 6 Jul 2020 19:23:35 +0000 (21:23 +0200)
committerMáté Kocsis <kocsismate@woohoolabs.com>
Mon, 6 Jul 2020 19:23:35 +0000 (21:23 +0200)
ext/intl/collator/collator_is_numeric.c
ext/intl/collator/collator_sort.c
ext/intl/dateformat/dateformat_format.c
ext/intl/dateformat/dateformat_parse.c
ext/intl/intl_error.c
ext/intl/locale/locale_methods.c

index dffa2c81b94cc17b3b12e56055b5cdaf17114e98..6f7311fa96070d96ed63bc571d874b705563e268 100644 (file)
@@ -15,9 +15,7 @@
 
 #include "collator_is_numeric.h"
 
-/* {{{ collator_u_strtod
- * Taken from PHP6:zend_u_strtod()
- */
+/* {{{ Taken from PHP6:zend_u_strtod() */
 static double collator_u_strtod(const UChar *nptr, UChar **endptr) /* {{{ */
 {
        const UChar *u = nptr, *nstart;
index 92ca0dc1323aa0bb9d12f9eca76717fe3c9fd6d2..444cbb72abcfbcc530540f7edcf81a67b14d63bb 100644 (file)
@@ -238,9 +238,7 @@ static int collator_compare_func(Bucket *f, Bucket *s)
 }
 /* }}} */
 
-/* {{{ collator_cmp_sort_keys
- * Compare sort keys
- */
+/* {{{ Compare sort keys */
 static int collator_cmp_sort_keys( const void *p1, const void *p2 )
 {
        char* key1 = ((collator_sort_key_index_t*)p1)->key;
@@ -250,9 +248,7 @@ static int collator_cmp_sort_keys( const void *p1, const void *p2 )
 }
 /* }}} */
 
-/* {{{ collator_get_compare_function
- * Choose compare function according to sort flags.
- */
+/* {{{ Choose compare function according to sort flags. */
 static collator_compare_func_t collator_get_compare_function( const zend_long sort_flags )
 {
        collator_compare_func_t func;
@@ -277,9 +273,7 @@ static collator_compare_func_t collator_get_compare_function( const zend_long so
 }
 /* }}} */
 
-/* {{{ collator_sort_internal
- * Common code shared by collator_sort() and collator_asort() API functions.
- */
+/* {{{ Common code shared by collator_sort() and collator_asort() API functions. */
 static void collator_sort_internal( int renumber, INTERNAL_FUNCTION_PARAMETERS )
 {
        zval           saved_collator;
@@ -342,8 +336,6 @@ static void collator_sortkey_swap(collator_sort_key_index_t *p, collator_sort_ke
 }
 /* }}} */
 
-/* {{{ Equivalent to standard PHP sort using Collator.
- * Uses ICU ucol_getSortKey for performance. }}} */
 /* {{{ Equivalent to standard PHP sort using Collator.
  * Uses ICU ucol_getSortKey for performance.
  */
index 82d25a148189856bf91cd021289fe3cce826d681..a76de1ed9afe81c75bc57db532ac2041d00aad6c 100644 (file)
@@ -27,7 +27,7 @@
 #include "dateformat_class.h"
 #include "dateformat_data.h"
 
-/* {{{ Internal function which calls the udat_format */
+/* {{{ Internal function which calls the udat_format */
 static void internal_format(IntlDateFormatter_object *dfo, UDate timestamp, zval *return_value)
 {
        UChar*  formatted =  NULL;
@@ -52,7 +52,7 @@ static void internal_format(IntlDateFormatter_object *dfo, UDate timestamp, zval
 /* }}} */
 
 
-/* {{{ Internal function which fetches an element from the passed array for the key_name passed */
+/* {{{ Internal function which fetches an element from the passed array for the key_name passed */
 static int32_t internal_get_arr_ele(IntlDateFormatter_object *dfo,
                HashTable* hash_arr, char* key_name, intl_error *err)
 {
@@ -88,7 +88,7 @@ static int32_t internal_get_arr_ele(IntlDateFormatter_object *dfo,
 }
 /* }}} */
 
-/* {{{ Internal function which sets UCalendar  from the passed array and retrieves timestamp */
+/* {{{ Internal function which sets UCalendar  from the passed array and retrieves timestamp */
 static UDate internal_get_timestamp(IntlDateFormatter_object *dfo,
                HashTable *hash_arr)
 {
index 17217a79234a6be16b7091328da60345f47a94b8..0089fbe5b63fbe11fe283f1174e07ab47ed23680 100644 (file)
@@ -75,7 +75,7 @@ static void add_to_localtime_arr( IntlDateFormatter_object *dfo, zval* return_va
        }
 }
 
-/* {{{ Internal function which calls the udat_parseCalendar */
+/* {{{ Internal function which calls the udat_parseCalendar */
 static void internal_parse_to_localtime(IntlDateFormatter_object *dfo, char* text_to_parse, size_t text_len, int32_t *parse_pos, zval *return_value)
 {
        UCalendar      *parsed_calendar = NULL;
index f2394df3710371eff2503d5f68a0fc9ffbbb0b23..6babe701529fe230ff7fd6e6c872f5cd0e792ae8 100644 (file)
@@ -29,18 +29,14 @@ ZEND_EXTERN_MODULE_GLOBALS( intl )
 
 zend_class_entry *IntlException_ce_ptr;
 
-/* {{{ intl_error* intl_g_error_get()
- * Return global error structure.
- */
+/* {{{ Return global error structure. */
 static intl_error* intl_g_error_get( void )
 {
        return &INTL_G( g_error );
 }
 /* }}} */
 
-/* {{{ void intl_free_custom_error_msg( intl_error* err )
- * Free mem.
- */
+/* {{{ Free mem. */
 static void intl_free_custom_error_msg( intl_error* err )
 {
        if( !err && !( err = intl_g_error_get(  ) ) )
@@ -55,9 +51,7 @@ static void intl_free_custom_error_msg( intl_error* err )
 }
 /* }}} */
 
-/* {{{ intl_error* intl_error_create()
- * Create and initialize  internals of 'intl_error'.
- */
+/* {{{ Create and initialize  internals of 'intl_error'. */
 intl_error* intl_error_create( void )
 {
        intl_error* err = ecalloc( 1, sizeof( intl_error ) );
@@ -68,9 +62,7 @@ intl_error* intl_error_create( void )
 }
 /* }}} */
 
-/* {{{ void intl_error_init( intl_error* coll_error )
- * Initialize internals of 'intl_error'.
- */
+/* {{{ Initialize internals of 'intl_error'. */
 void intl_error_init( intl_error* err )
 {
        if( !err && !( err = intl_g_error_get(  ) ) )
@@ -82,9 +74,7 @@ void intl_error_init( intl_error* err )
 }
 /* }}} */
 
-/* {{{ void intl_error_reset( intl_error* err )
- * Set last error code to 0 and unset last error message
- */
+/* {{{ Set last error code to 0 and unset last error message */
 void intl_error_reset( intl_error* err )
 {
        if( !err && !( err = intl_g_error_get(  ) ) )
@@ -96,9 +86,7 @@ void intl_error_reset( intl_error* err )
 }
 /* }}} */
 
-/* {{{ void intl_error_set_custom_msg( intl_error* err, char* msg, int copyMsg )
- * Set last error message to msg copying it if needed.
- */
+/* {{{ Set last error message to msg copying it if needed. */
 void intl_error_set_custom_msg( intl_error* err, const char* msg, int copyMsg )
 {
        if( !msg )
@@ -124,9 +112,7 @@ void intl_error_set_custom_msg( intl_error* err, const char* msg, int copyMsg )
 }
 /* }}} */
 
-/* {{{ const char* intl_error_get_message( intl_error* err )
- * Create output message in format "<intl_error_text>: <extra_user_error_text>".
- */
+/* {{{ Create output message in format "<intl_error_text>: <extra_user_error_text>". */
 zend_string * intl_error_get_message( intl_error* err )
 {
        const char *uErrorName = NULL;
@@ -151,9 +137,7 @@ zend_string * intl_error_get_message( intl_error* err )
 }
 /* }}} */
 
-/* {{{ void intl_error_set_code( intl_error* err, UErrorCode err_code )
- * Set last error code.
- */
+/* {{{ Set last error code. */
 void intl_error_set_code( intl_error* err, UErrorCode err_code )
 {
        if( !err && !( err = intl_g_error_get(  ) ) )
@@ -163,9 +147,7 @@ void intl_error_set_code( intl_error* err, UErrorCode err_code )
 }
 /* }}} */
 
-/* {{{ void intl_error_get_code( intl_error* err )
- * Return last error code.
- */
+/* {{{ Return last error code. */
 UErrorCode intl_error_get_code( intl_error* err )
 {
        if( !err && !( err = intl_g_error_get(  ) ) )
@@ -175,9 +157,7 @@ UErrorCode intl_error_get_code( intl_error* err )
 }
 /* }}} */
 
-/* {{{ void intl_error_set( intl_error* err, UErrorCode code, char* msg, int copyMsg )
- * Set error code and message.
- */
+/* {{{ Set error code and message. */
 void intl_error_set( intl_error* err, UErrorCode code, const char* msg, int copyMsg )
 {
        intl_error_set_code( err, code );
@@ -185,9 +165,7 @@ void intl_error_set( intl_error* err, UErrorCode code, const char* msg, int copy
 }
 /* }}} */
 
-/* {{{ void intl_errors_set( intl_error* err, UErrorCode code, char* msg, int copyMsg )
- * Set error code and message.
- */
+/* {{{ Set error code and message. */
 void intl_errors_set( intl_error* err, UErrorCode code, const char* msg, int copyMsg )
 {
        intl_errors_set_code( err, code );
@@ -195,7 +173,7 @@ void intl_errors_set( intl_error* err, UErrorCode code, const char* msg, int cop
 }
 /* }}} */
 
-/* {{{ void intl_errors_reset( intl_error* err ) */
+/* {{{ */
 void intl_errors_reset( intl_error* err )
 {
        if(err) {
@@ -205,7 +183,7 @@ void intl_errors_reset( intl_error* err )
 }
 /* }}} */
 
-/* {{{ void intl_errors_set_custom_msg( intl_error* err, char* msg, int copyMsg ) */
+/* {{{ */
 void intl_errors_set_custom_msg( intl_error* err, const char* msg, int copyMsg )
 {
        if(err) {
@@ -215,7 +193,7 @@ void intl_errors_set_custom_msg( intl_error* err, const char* msg, int copyMsg )
 }
 /* }}} */
 
-/* {{{ intl_errors_set_code( intl_error* err, UErrorCode err_code ) */
+/* {{{ */
 void intl_errors_set_code( intl_error* err, UErrorCode err_code )
 {
        if(err) {
index d48cfeff03b9e0a38e5d23322ec8b4dbd91fc432..2b166b74dce981a151266caa8eeb2eb75e15a76e 100644 (file)
@@ -1121,7 +1121,7 @@ PHP_FUNCTION(locale_get_all_variants)
 }
 /* }}} */
 
-/* {{{ Converts to lower case and also replaces all hyphens with the underscore */
+/* {{{ Converts to lower case and also replaces all hyphens with the underscore */
 static int strToMatch(const char* str ,char *retstr)
 {
        char*   anchor  = NULL;