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

Bug 457044

Summary: [eslint] missing-doc rule fails with line comment on previous line
Product: [ECD] Orion Reporter: Michael Rennie <Michael_Rennie>
Component: JS ToolsAssignee: Michael Rennie <Michael_Rennie>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 8.0   
Target Milestone: 8.0   
Hardware: PC   
OS: Mac OS X   
Whiteboard:

Description Michael Rennie CLA 2015-01-08 11:19:25 EST
Consider the following snippet:

var s = 'hello'  //$NON-NLS-0$
function f2() {}

If you have the missing-doc rule turned on f2 is not flagged as having missing doc - but it should be. If the leading comment is not JSDoc-like we should be flagging it.

For example:

var s = 'hello'  /** some comment */
function f2() {}

should not be flagged because the doc is JSDoc-like and does precede the function.