Skip to content

Conversation

@beberlei
Copy link
Contributor

@beberlei beberlei commented Sep 15, 2019

There are a bunch of classes that are not documented in php.net docs and have never been implemented. They even contain test data in their properties. Example:

$ php -r 'var_dump(new DOMNameList());'
object(DOMNameList)#1 (1) {
  ["length"]=>
  string(4) "TEST"
 }

In the extension to the DOM standard (PHP implements level 1, 2, 3 to some extend) called DOM living standard these classes have been removed as well: https://dom.spec.whatwg.org/#dom-core-changes

The affected (and therefore removed) classes are:

  • DOMConfiguration
  • DOMDomError
  • DOMErrorHandler
  • DOMImplementationList
  • DOMImplementationSource
  • DOMLocator
  • DOMNameList
  • DOMTypeInfo
  • DOMUserDataHandler

While this looks like a backwards compatibility break, nobody will use these classes in production, because they have no behavior, and also were never "reachable" or returned from the actively used DOM classes as part of a return value or a public property.

Copy link
Member

@KalleZ KalleZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see any problem doing this for master. Any non operational userland code shouldn't be exposed by internals at the very least.

@beberlei
Copy link
Contributor Author

Merged in 25bfac4

@beberlei beberlei closed this Sep 17, 2019
@carusogabriel carusogabriel added this to the PHP 8.0 milestone May 29, 2020
nicolas-grekas added a commit to symfony/symfony that referenced this pull request Apr 19, 2022
…emoved DOM classes (fancyweb)

This PR was merged into the 6.1 branch.

Discussion
----------

[VarDumper] Remove casters for mysql link resource and removed DOM classes

| Q             | A
| ------------- | ---
| Branch?       | 6.1
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

`\DOMTypeinfo`, `\DOMDomError` and `\DOMLocator` have been removed in PHP 8.0 (php/php-src#4707).
`mysql link` resource looks impossible because the `mysql` extension has been removed in PHP 7.0.

Commits
-------

a506f9c [VarDumper] Remove casters for mysql link resource and removed DOM classes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants