Bug#535601: Indent changes file twice when called twice (fwd)

View: New views
1 Messages — Rating Filter:   Alert me  

Bug#535601: Indent changes file twice when called twice (fwd)

by Santiago Vila :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello.

I received this from the Debian bug system:

---------- Forwarded message ----------
From: Joachim Zobel <jzobel@...>
To: submit@...
Date: Fri, 03 Jul 2009 08:12:49 +0200
Subject: Bug#535601: Indent changes file twice when called twice

Package: indent
Version: 2.2.10-1
Severity: normal

We have found that indent changes some files back and forth. Here is an
example that reproduces the problem:

jzobel@test$ cp test_indent.c test_indent.c.org
jzobel@test$ indent -kr --no-tabs test_indent.c
jzobel@test$ diff test_indent.c test_indent.c.org
18,19c18,19
<     return
bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->
<         bar->bar->bar->bar->bar;
---
>     return bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->
>         bar->bar->bar->bar->bar->bar;
jzobel@test$ indent -kr --no-tabs test_indent.c
jzobel@test$ diff test_indent.c test_indent.c.org
jzobel@test$

Sincerely,
Joachim

[test_indent.c]

/*
***********************************************************************
*                                                                     *
* Test for an indent bug.                                             *
*                                                                     *
***********************************************************************
*/


/*
  Test for an indent bug
*/

void foo()
{
    return bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->bar->
        bar->bar->bar->bar->bar->bar;

}


_______________________________________________
bug-indent mailing list
bug-indent@...
http://lists.gnu.org/mailman/listinfo/bug-indent