This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 198630 - Wrong formatting when changing multiple expressionStatements
Summary: Wrong formatting when changing multiple expressionStatements
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 7.0.1
Hardware: PC All
: P3 normal (vote)
Assignee: Jan Lahoda
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-16 12:36 UTC by Ralph Ruijs
Modified: 2011-05-23 09:09 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Testcase (5.87 KB, text/plain)
2011-05-16 12:38 UTC, Ralph Ruijs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Ruijs 2011-05-16 12:36:23 UTC
I try to inline the method printGreeting but the first two lines end up on the same line (and an empty line at the end). Like:

public class MultipleExpressionsTest {
    public void testMethod() {
        System.out.println("Hello World!");System.out.println("Hello World!");
        System.out.println("Hello World!");

    }
    public void printGreeting() {
        System.out.println("Hello World!");
    }
}

I think this is a problem in CasualDiff.
Comment 1 Ralph Ruijs 2011-05-16 12:38:02 UTC
Created attachment 108317 [details]
Testcase
Comment 2 Jan Lahoda 2011-05-19 12:37:16 UTC
http://hg.netbeans.org/jet-main/rev/9542a0364119
Comment 3 Quality Engineering 2011-05-20 08:55:48 UTC
Integrated into 'main-golden', will be available in build *201105200400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/9542a0364119
User: Jan Lahoda <jlahoda@netbeans.org>
Log: #198630: fixing rewrite of statements in blocks.
Comment 4 Jan Lahoda 2011-05-23 09:09:40 UTC
release701:
http://hg.netbeans.org/releases/rev/83e220e6f720