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

Bug 360439

Summary: [editor] Wrong folding with function inside an object
Product: [WebTools] JSDT Reporter: Shedokan <shedokan1>
Component: GeneralAssignee: Project Inbox <jsdt.javascript-inbox>
Status: NEW --- QA Contact: Chris Jaun <cmjaun>
Severity: normal    
Priority: P3 CC: shedokan1, wywrzal
Version: 3.3.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Shedokan CLA 2011-10-10 09:53:19 EDT
Build Identifier: 

With this code:
function someFunction(){
	// Some comment
	bla = '';
}

var a = {
	someMethod: function(){
	}
};

The editor tells me I can fold "bla = '';" and when I do it folds up until the end of the "a" object.

But when I remove "someMethod" or remove the comment or move the comment to the same line as "bla" the problem disappears.
It also bugs with any type of comment(Multiline and JSDoc)

Reproducible: Always

Steps to Reproduce:
1. Open a new javascript file
2. paste the code I gave