mirror of
https://github.com/php/php-src.git
synced 2025-08-16 14:08:47 +02:00
[ci skip] Update UPGRADING.INTERNALS
This commit is contained in:
parent
941a7e59d9
commit
b4917d8a19
1 changed files with 11 additions and 9 deletions
|
@ -121,21 +121,23 @@ PHP 8.3 INTERNALS UPGRADE NOTES
|
|||
properties in a read-only way. This function avoids allocation when there are
|
||||
no document properties changed yet.
|
||||
- The node list returned by DOMNode::getElementsByTagName() and
|
||||
DOMNode::getElementsByTagNameNS() now caches the length and the last requested item.
|
||||
This means that the length and the last requested item are not recalculated
|
||||
when the node list is iterated over multiple times.
|
||||
If you do not use the internal PHP dom APIs to modify the document, you need to
|
||||
manually invalidate the cache using php_libxml_invalidate_node_list_cache_from_doc().
|
||||
Furthermore, the following internal APIs were added to handle the cache:
|
||||
. php_dom_is_cache_tag_stale_from_doc_ptr()
|
||||
. php_dom_is_cache_tag_stale_from_node()
|
||||
. php_dom_mark_cache_tag_up_to_date_from_node()
|
||||
DOMNode::getElementsByTagNameNS() now caches the length and the last requested item.
|
||||
This means that the length and the last requested item are not recalculated
|
||||
when the node list is iterated over multiple times.
|
||||
If you do not use the internal PHP dom APIs to modify the document, you need to
|
||||
manually invalidate the cache using php_libxml_invalidate_node_list_cache_from_doc().
|
||||
Furthermore, the following internal APIs were added to handle the cache:
|
||||
. php_dom_is_cache_tag_stale_from_doc_ptr()
|
||||
. php_dom_is_cache_tag_stale_from_node()
|
||||
. php_dom_mark_cache_tag_up_to_date_from_node()
|
||||
- The function dom_get_elements_by_tag_name_ns_raw() has an additional parameter to indicate
|
||||
the base node of the node list. This function also no longer accepts -1 as the index argument.
|
||||
- The function dom_namednode_iter() has additional arguments to avoid recomputing the length of
|
||||
the strings.
|
||||
- The functions dom_parent_node_prepend(), dom_parent_node_append(), dom_parent_node_after(), and
|
||||
dom_parent_node_before() now use an uint32_t argument for the number of nodes instead of int.
|
||||
- There is now a helper function php_dom_get_content_into_zval() to get the contents of a node.
|
||||
This avoids allocation if possible.
|
||||
|
||||
g. ext/libxml
|
||||
- Two new functions: php_libxml_invalidate_node_list_cache_from_doc() and
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue