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

Bug 423357

Summary: Pressing ENTER on a // line comment breaks the editor
Product: [ECD] Orion Reporter: Mark Macdonald <mamacdon>
Component: EditorAssignee: Grant Gayed <grant_gayed>
Status: RESOLVED FIXED QA Contact:
Severity: blocker    
Priority: P3    
Version: 5.0   
Target Milestone: 5.0 M1   
Hardware: PC   
OS: All   
Whiteboard:

Description Mark Macdonald CLA 2013-12-05 13:54:46 EST
1. Ensure you're self hosting off of master
2. Open up astManager.js
3. Place the caret at the end of line 50:
> 	// TODO wrap in try..catch to recover from parse errors in initial statements of code
>                                                                                            ^ put caret here
4. Press ENTER
5. A JS error is thrown. The text buffer appears corrupt and editor actions stop stop working.

> Uncaught TypeError: Cannot call method 'substring' of undefined textModel.js:402
> TextModel.getText textModel.js:402
> (anonymous function) textStyler.js:294

I bisected this to the following commit:

> d69ef015df0fcd0f4c261d3905926bf329f6a9e9 is the first bad commit
>     Bug 423272 - TODO bubbles are not shown until they appear in the editor viewport (single-line comments now handled)