Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 322479

Summary: [Content Assist] constructor method should not be proposed by code assist
Product: z_Archived Reporter: Roy Ganor <ganoro>
Component: PDTAssignee: Zhongwei Zhao <zhaozhongwei>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P1 CC: petyo_tanchev
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Roy Ganor CLA 2010-08-12 04:41:49 EDT
Code:
class person {
    private $name;
    
    function __construct($name) {
        $this->setName($name);
    }
    /**
     * @return the $name
     */
    public function getName() {
        return $this->name;
    }

    /**
     * @param field_type $name
     */
    public function setName($name) {
        $this->name = $name;
    }

}

$x = new person("gadi");

echo $x->| should not show constructor
Comment 1 Zhongwei Zhao CLA 2010-08-19 22:13:09 EDT
fixed in head and branch
Comment 2 Zhongwei Zhao CLA 2010-08-20 00:17:04 EDT
there is one case I have not fixed:
we can call superclass' constructor in any of subclass' method
Comment 3 Zhongwei Zhao CLA 2010-08-23 05:18:21 EDT
fixed in head and branch
Comment 4 Petyo Tanchev CLA 2010-08-31 10:52:47 EDT
Tested on 2.2.1.v20100829
Fixed