Hi Thomas,

Inline Variable refactoring is improved this way in #505.
Thanks for mentioning!

Best regards,
Eugene Zhuravlev,
IntelliJ Software, http://www.intellij.com/
"Develop with pleasure"


----- Original Message -----
From: "Thomas Singer" <[EMAIL PROTECTED]>
To: "'_EAP Bugs'" <[EMAIL PROTECTED]>
Sent: Friday, September 21, 2001 15:20
Subject: [Eap-list] Inline variable


> Hello,
>
> I had following code:
>
>  QXmlAttribute attribute = rootElement.getAttribute("prop1");
>  assertEquals("value1", attribute.getValue());
>
>  attribute = rootElement.getAttribute("prop2");
>  assertEquals("value2", attribute.getValue());
>
> Now I wanted to inline the first occurence of "attribute". But IDEA tells
me
> "Cannot inline local variable attribute: the variable is accessed for
> writing." :( I hoped, that IDEA is a little bit smarter and produces
> following:
>
>  QXmlAttribute attribute;
>  assertEquals("value1", rootElement.getAttribute("prop1").getValue());
>
>  attribute = rootElement.getAttribute("prop2");
>  assertEquals("value2", attribute.getValue());
>
> I believe, this isn't really difficult to implement: replace only the
> occurenced, that are before it is accessed a second time.
>
> Regards
> Thomas Singer
> _____________
>     regnis.de
>
>
> _______________________________________________
> Eap-list mailing list
> [EMAIL PROTECTED]
> http://www.intellij.com/mailman/listinfo/eap-list


_______________________________________________
Eap-list mailing list
[EMAIL PROTECTED]
http://www.intellij.com/mailman/listinfo/eap-list

Reply via email to