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

Bug 320404

Summary: phpdoc generation ignores templates
Product: z_Archived Reporter: Philip Taffner <sabel>
Component: PDTAssignee: PHP Core <php.core-inbox>
Status: CLOSED FIXED QA Contact:
Severity: major    
Priority: P3 CC: gadi
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Philip Taffner CLA 2010-07-20 11:19:30 EDT
Build Identifier: 20100617-1415

I changed the template under Preferences->PHP->Code Style->Code Templates->Methods
to:

/**
 * ${cursor}
 * ${tags}
 */

Now I have the following simple Code (| is the cursor):

class Test {
	|
	public function foo($bar, $baz){
	}	
}

When I type /** and hit return, it generates me two differents phpdoc code blocks (Ctrl+Shift+J has the same effect):

1)
/**
 * |
 * Enter description here ...
 * @param unknown_type $bar
 * @param unknown_type $baz
 */
public function foo($bar, $baz){
}

and sometimes:

/**
 * |
 * Enter description here ...
 * @param $bar
 * @param $baz
 */
public function foo($bar, $baz){
}

So first my template is ignored and second the result switches between those two possibilities.

This issue affects ALL templates as far as I can tell.

Fresh install and new workspace.

Reproducible: Always
Comment 1 Zhongwei Zhao CLA 2010-07-21 02:07:57 EDT
fixed in head
Comment 2 Zhongwei Zhao CLA 2010-07-21 02:10:27 EDT
mark as fixed
Comment 3 Gadi Goldbarg CLA 2010-08-23 04:15:24 EDT
Verified fixed.
Kalin Yanev
kalin.a@zend.com