This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 245318 - Method inline refactoring removes class-level comments
Summary: Method inline refactoring removes class-level comments
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 8.0.1
Hardware: PC Windows 7
: P2 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on: 239487
Blocks:
  Show dependency tree
 
Reported: 2014-06-30 11:40 UTC by Maksim Khramov
Modified: 2014-07-10 14:28 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maksim Khramov 2014-06-30 11:40:37 UTC
Product Version: NetBeans IDE Dev (Build 201406300002)
Java: 1.8.0_25-ea; Java HotSpot(TM) 64-Bit Server VM 25.25-b01
Runtime: Java(TM) SE Runtime Environment 1.8.0_25-ea-b01

Steps to reporoduce:

Create new class to test:
/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package javaapplication17;

/**
 * <p>
 * Page bean that corresponds to a similarly named JSP page.
 *
 * @author Author
 */
//@ManagedBean(name="SomeBean")
//@RequestScoped
public class JavaApplication17 {


    public static void main(String[] args) {
        // TODO code application logic here
        methodToInline();
    }
    
    private static void methodToInline() {
        System.out.println("To be inlined;");
    }
    
}

Invoke inline method refactoring.
The comments before class are disappears
Comment 1 Svata Dedic 2014-07-02 08:41:44 UTC
Can be fixed in java code generator.
Comment 2 Svata Dedic 2014-07-10 14:28:12 UTC
Fixed by general support implemented as part of issue #239487 and isssue #245348