RB doesn't preserve code formatting even in the simplest cases.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

RB doesn't preserve code formatting even in the simplest cases.

George Herolyants-3
Just an example: given there is a method without arguments which has
several statements separated by empty lines. If you then try to rename
this method you lose all the empty lines.

I've checked it in the latest pharo-dev and in pharo-core 10491 with
the latest AST-Core-lr.30, Refactoring-Core-lr.77 and
OB-Refactory-lr.170.

I've opened an issue: http://code.google.com/p/pharo/issues/detail?id=1493

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: RB doesn't preserve code formatting even in the simplest cases.

Lukas Renggli
I cannot reproduce. Can you try to rename a variable or class, because
that should always work. Also make sure that you actually apply the
refactoring, because in the changes browser the output is typically
pretty printed for improved diffs.

Lukas

On Monday, November 23, 2009, George Herolyants
<[hidden email]> wrote:

> Just an example: given there is a method without arguments which has
> several statements separated by empty lines. If you then try to rename
> this method you lose all the empty lines.
>
> I've checked it in the latest pharo-dev and in pharo-core 10491 with
> the latest AST-Core-lr.30, Refactoring-Core-lr.77 and
> OB-Refactory-lr.170.
>
> I've opened an issue: http://code.google.com/p/pharo/issues/detail?id=1493
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

--
Lukas Renggli
http://www.lukas-renggli.ch

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: RB doesn't preserve code formatting even in the simplest cases.

George Herolyants-3
Rename of the temp variable works fine, but rename of the method still
breaks formatting (in preview and after applying too). Checked in
pharo-dev 09.11.4 on BitBltTest>>testAlphaCompositing.

2009/11/23 Lukas Renggli <[hidden email]>:

> I cannot reproduce. Can you try to rename a variable or class, because
> that should always work. Also make sure that you actually apply the
> refactoring, because in the changes browser the output is typically
> pretty printed for improved diffs.
>
> Lukas
>
> On Monday, November 23, 2009, George Herolyants
> <[hidden email]> wrote:
>> Just an example: given there is a method without arguments which has
>> several statements separated by empty lines. If you then try to rename
>> this method you lose all the empty lines.
>>
>> I've checked it in the latest pharo-dev and in pharo-core 10491 with
>> the latest AST-Core-lr.30, Refactoring-Core-lr.77 and
>> OB-Refactory-lr.170.
>>
>> I've opened an issue: http://code.google.com/p/pharo/issues/detail?id=1493
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: RB doesn't preserve code formatting even in the simplest cases.

Lukas Renggli
Aha, I see. Renaming reformats the implementors, but not the senders.

This is fixed in Refactoring-Core-lr.78.

Name: Refactoring-Core-lr.78
Author: lr
Time: 23 November 2009, 11:11:43 am
UUID: 411320fe-57e6-4e6e-ae64-a9ab37f2d178
Ancestors: Refactoring-Core-lr.77

- don't reformat method signatures when renaming a method, when
extracting a method, when inlining a method and when moving a method

2009/11/23 George Herolyants <[hidden email]>:

> Rename of the temp variable works fine, but rename of the method still
> breaks formatting (in preview and after applying too). Checked in
> pharo-dev 09.11.4 on BitBltTest>>testAlphaCompositing.
>
> 2009/11/23 Lukas Renggli <[hidden email]>:
>> I cannot reproduce. Can you try to rename a variable or class, because
>> that should always work. Also make sure that you actually apply the
>> refactoring, because in the changes browser the output is typically
>> pretty printed for improved diffs.
>>
>> Lukas
>>
>> On Monday, November 23, 2009, George Herolyants
>> <[hidden email]> wrote:
>>> Just an example: given there is a method without arguments which has
>>> several statements separated by empty lines. If you then try to rename
>>> this method you lose all the empty lines.
>>>
>>> I've checked it in the latest pharo-dev and in pharo-core 10491 with
>>> the latest AST-Core-lr.30, Refactoring-Core-lr.77 and
>>> OB-Refactory-lr.170.
>>>
>>> I've opened an issue: http://code.google.com/p/pharo/issues/detail?id=1493
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>
>>
>> --
>> Lukas Renggli
>> http://www.lukas-renggli.ch
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



--
Lukas Renggli
http://www.lukas-renggli.ch

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: RB doesn't preserve code formatting even in the simplest cases.

George Herolyants-3
Great! Thank you very much!

2009/11/23 Lukas Renggli <[hidden email]>:

> Aha, I see. Renaming reformats the implementors, but not the senders.
>
> This is fixed in Refactoring-Core-lr.78.
>
> Name: Refactoring-Core-lr.78
> Author: lr
> Time: 23 November 2009, 11:11:43 am
> UUID: 411320fe-57e6-4e6e-ae64-a9ab37f2d178
> Ancestors: Refactoring-Core-lr.77
>
> - don't reformat method signatures when renaming a method, when
> extracting a method, when inlining a method and when moving a method
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project