Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 335634 - [Auto Edit] ML comment in SL comment produces bad result in xtext editor
Summary: [Auto Edit] ML comment in SL comment produces bad result in xtext editor
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 2.0.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: M7   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-27 18:04 EST by Henrik Lindberg CLA
Modified: 2017-09-19 17:44 EDT (History)
2 users (show)

See Also:
sven.efftinge: indigo+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Henrik Lindberg CLA 2011-01-27 18:04:21 EST
Reproducible in Xtext 2.0 editor (i.e. edit MyDSL.xtext).

Type :
// xxx /*

(with caret after the *) when hitting return the result is:

// xxx /*
               *
               */
Comment 1 Henrik Lindberg CLA 2011-01-27 18:08:24 EST
I guess this is just another variant on "regions" not being skipped.

Other bad auto edits happen
Example:

With this text
// ML_COMMENT PATTERN: '/ *' '/'* ( !('*' | '/') | !'*' '/' | '*' !'/')* '*'+ '/'
//

Hitting return to create a new empty line, the editor inserts ';' to complete the commented out rule.
Comment 2 Sebastian Zarnekow CLA 2011-04-11 08:22:07 EDT
Pushed to master.
Comment 3 Karsten Thoms CLA 2017-09-19 17:33:09 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 4 Karsten Thoms CLA 2017-09-19 17:44:21 EDT
Closing all bugs that were set to RESOLVED before Neon.0