Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 286654

Summary: [formatter] Single line comment causes indentation on Formatting
Product: [WebTools] JSDT Reporter: Jaap <jaap>
Component: GeneralAssignee: wst.javascript <wst.javascript-inbox>
Status: CLOSED DUPLICATE QA Contact: Nitin Dahyabhai <thatnitind>
Severity: normal    
Priority: P3 CC: cmjaun
Version: 3.1   
Target Milestone: 3.2 RC4   
Hardware: PC   
OS: Windows Vista   
Whiteboard:

Description Jaap CLA 2009-08-14 11:51:25 EDT
Build ID: 20090621-0832

Steps To Reproduce:
1.
Paste the script (a snippet of demo.js from the mootools Form.Send example)
2.
Run Formatting, Shift+Ctrl+F
3.
The indentation is wrong. The first comment within a block statement (curly braces) seems to cause the other lines in the blockstatement to indent one extra time (this is not consistent however, the onComplete function doesn't contain extra indentation)...

I've tried to adjust some settings in the formatting profile for javascript files, couldn't find a solution there.

I think it's a bug!

More information:
I've installed a fresh Java EE version of Galileo, added the pydev feature.

The script I'm using:

window.addEvent('domready', function() {
  // You can skip the following two lines of code. We need them to make sure
    // demos are runnable on MooTools demos web page.

  });
Comment 1 Chris Jaun CLA 2009-09-15 15:43:19 EDT
Categorizing JSDT bugzillas for planning purposes.
Comment 2 Chris Jaun CLA 2010-06-22 13:35:17 EDT

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