Bug 40996 - line comments confuse formatter
Summary: line comments confuse formatter
Status: RESOLVED DUPLICATE of bug 40777
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.1.1   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0 M3   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-07-31 08:45 EDT by Ilja Preuss CLA
Modified: 2003-07-31 08:52 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ilja Preuss CLA 2003-07-31 08:45:07 EDT
The following code gets formatted correctly:

public class Foo {
  public void foo() {
    Action action = new AbstractAction("name") {
      public void actionPerformed(ActionEvent e) {
      }
    };
  }
}

If you add a comment (for example a $NON-NLS comment) at the end of the third 
line, the formatter seems to get confused:

public class Foo {
  public void foo() {
      Action action = new AbstractAction("name") { // $NON-NLS
  public void actionPerformed(ActionEvent e) {
      }
    };
  }
}
Comment 1 Olivier Thomann CLA 2003-07-31 08:52:30 EDT

*** This bug has been marked as a duplicate of 40777 ***