You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Renaming a parameter that have the same name of one of declared attributes will causes a conflict. This plugin will select the @attribute and if you apply the renaming process you will have a PS exception.
For instance:
class Test
{
/**
* @param $param
*/
public function test($param)
{
}
}
Select $param and call rename (Refactor / Rename...), it'll select both $param, but will include too @param. If you try to rename it to, for instance, $test, the code will seems like:
class Test
{
/**
* @[test] $[test]
*/
public function test($[test])
{
}
}
After you press enter to confirm the renaming, it'll displays the Refactoring Preview window with three options (both $param and too @param). If you just do refactoring as is, it'll rename the code to:
class Test
{
/**
* @param $[test]
*/
public function test($param)
{
}
}
Note that it will rename only the annotation parameter, but will not affects the @param (will back to normal), but too will not apply on method parameter (will back to $param). It occur because an exception is thrown after you try do that (full exception log).
Cannot find manipulator for phpDocParam in phpDocParam:null class class
de.espend.idea.php.annotation.reference.
DocTagNameAnnotationReferenceContributor$PhpDocTagReference
java.lang.Throwable
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:132)
at com.intellij.psi.PsiReferenceBase.getManipulator(PsiReferenceBase.java:139)
at com.intellij.psi.PsiReferenceBase.handleElementRename(PsiReferenceBase.java:115)
at com.intellij.refactoring.rename.RenameUtil.rename(RenameUtil.java:266)
...
This issue was registered on Jetbrains Youtrack too, but was not related to this platform. WI-33848
Plugin Version
PHP Annotations 4.2
Software Version
PhpStorm 2016.3 EAP
Build #PS-163.7342.9, built on November 2, 2016
JRE: 1.8.0_112-release-408-b2 x86
JVM: OpenJDK Server VM by JetBrains s.r.o
The text was updated successfully, but these errors were encountered:
Renaming a parameter that have the same name of one of declared attributes will causes a conflict. This plugin will select the
@attribute
and if you apply the renaming process you will have a PS exception.For instance:
Select
$param
and call rename (Refactor / Rename...), it'll select both$param
, but will include too@param
. If you try to rename it to, for instance,$test
, the code will seems like:After you press enter to confirm the renaming, it'll displays the Refactoring Preview window with three options (both
$param
and too@param
). If you just do refactoring as is, it'll rename the code to:Note that it will rename only the annotation parameter, but will not affects the
@param
(will back to normal), but too will not apply on method parameter (will back to$param
). It occur because an exception is thrown after you try do that (full exception log).You can check this issue on this video (unlisted): PHP Annotations 4.2 issue.
This issue was registered on Jetbrains Youtrack too, but was not related to this platform. WI-33848
The text was updated successfully, but these errors were encountered: