Skip to content
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

Changed name of constructor. #12

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open

Changed name of constructor. #12

wants to merge 1 commit into from

Conversation

jakon89
Copy link

@jakon89 jakon89 commented Dec 6, 2014

"As of PHP 5.3.3, methods with the same name as the last element of a namespaced class name will no longer be treated as constructor. This change doesn't affect non-namespaced classes. "
Source: http://php.net/manual/en/language.oop5.decon.php

"As of PHP 5.3.3, methods with the same name as the last element of a namespaced class name will no longer be treated as constructor. This change doesn't affect non-namespaced classes. "
Source: http://php.net/manual/en/language.oop5.decon.php

<?php
namespace Foo;
class Bar {
    public function Bar() {
        // treated as constructor in PHP 5.3.0-5.3.2
        // treated as regular method as of PHP 5.3.3
    }
}
?>
jessedc added a commit to jessedc/PHP-Serial that referenced this pull request Mar 31, 2018
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.

1 participant