8000 [Debug] generalize deprecated interfaces tracking by nicolas-grekas · Pull Request #13665 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Debug] generalize deprecated interfaces tracking #13665

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 12, 2015

Conversation

nicolas-grekas
Copy link
Member
Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #13544
License MIT
Doc PR -

foreach ($refl->getInterfaceNames() as $interface) {
if (isset(self::$deprecated[$interface]) && ($len < 2 || strncmp($name, $interface, $len)) && !($parent && $parent->implementsInterface($interface))) {
trigger_error(sprintf('The %s %s %s that is deprecated %s', $name, $refl->isInterface() ? 'interface extends' : 'class implements', $interface, self::$deprecated[$interface]), E_USER_DEPRECATED);
}
Copy link
Member

Choose a reason for hiding this comment

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

Don't we have tests for that feature? It would make sense to have some.

Copy link
Member Author

Choose a reason for hiding this comment

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

Test added

@fabpot
Copy link
Member
fabpot commented Feb 12, 2015

Thank you @nicolas-grekas.

@fabpot fabpot merged commit a756f5b into symfony:2.7 Feb 12, 2015
fabpot added a commit that referenced this pull request Feb 12, 2015
…olas-grekas)

This PR was merged into the 2.7 branch.

Discussion
----------

[Debug] generalize deprecated interfaces tracking

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #13544
| License       | MIT
| Doc PR        | -

Commits
-------

a756f5b [Debug] generalize deprecated interfaces tracking
@nicolas-grekas nicolas-grekas deleted the generic-debug-deprec branch February 23, 2015 14:09
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.

2 participants
0