Changeset 250 for trunk/ext/php
- Timestamp:
- 03/04/2007 09:56:39 (21 months ago)
- Files:
-
- 1 modified
-
trunk/ext/php/phpext.c (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ext/php/phpext.c
r249 r250 23 23 #define PHP_SYCK_VERSION "0.2" 24 24 25 /** 26 * SyckException class 27 **/ 25 28 #define PHP_SYCK_EXCEPTION_PARENT "UnexpectedValueException" 26 29 #define PHP_SYCK_EXCEPTION_PARENT_LC "unexpectedvalueexception" … … 28 31 29 32 static zend_class_entry *spl_ce_RuntimeException; 33 zend_class_entry *syck_exception_entry; 30 34 31 35 PHP_SYCK_API zend_class_entry *php_syck_get_exception_base() … … 95 99 #endif 96 100 97 98 99 /**100 * "Merge" class101 **/102 /*static int le_mergekeyp;103 zend_class_entry *merge_key_entry;104 105 static zend_function_entry mergekey_functions[] = {106 PHP_FALIAS(mergekey, mergekey_init, NULL)107 { NULL, NULL, NULL }108 };109 110 PHP_FUNCTION(mergekey_init)111 {112 object_init_ex(getThis(), merge_key_entry);113 }114 115 static void destroy_MergeKey_resource(zend_rsrc_list_entry *resource TSRMLS_DC)116 {117 }118 */119 120 /**121 * SyckException class122 **/123 124 zend_class_entry *syck_exception_entry;125 126 101 PHP_MINIT_FUNCTION(syck) 127 102 { … … 130 105 INIT_CLASS_ENTRY(ce, PHP_SYCK_EXCEPTION_NAME, NULL); 131 106 syck_exception_entry = zend_register_internal_class_ex(&ce, php_syck_get_exception_base(), PHP_SYCK_EXCEPTION_PARENT TSRMLS_CC); 132 133 /* le_mergekeyp = zend_register_list_destructors_ex(destroy_MergeKey_resource, NULL, "MergeKey", module_number);134 INIT_CLASS_ENTRY(ce, "mergekey", mergekey_functions);135 merge_key_entry = zend_register_internal_class(&ce TSRMLS_CC);136 */137 107 return SUCCESS; 138 108 } 139 140 PHP_MSHUTDOWN_FUNCTION(syck)141 {142 /* uncomment this line if you have INI entries143 UNREGISTER_INI_ENTRIES();144 */145 return SUCCESS;146 }147 148 109 149 110 PHP_MINFO_FUNCTION(syck) … … 154 115 php_info_print_table_end(); 155 116 } 156 157 117 158 118 … … 195 155 ZVAL_DOUBLE(o, -inf()); 196 156 } else if (strcmp(n->type_id, "merge") == 0) { 197 /* This thing doesn't work, anyway */ 198 /* TSRMLS_FETCH(); 157 /* This thing doesn't work, anyway */ 158 /* 159 TSRMLS_FETCH(); 199 160 object_init_ex(o, merge_key_entry); 200 */ } else { 161 */ 162 } else { 201 163 ZVAL_STRINGL(o, n->data.str->ptr, n->data.str->len, 1); 202 164 } … … 237 199 zend_throw_exception(syck_exception_entry, str, 0 TSRMLS_CC); 238 200 } 201 239 202 240 203 /* {{{ proto object syck_load(string arg)