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 69649

Summary: The initializer of a java filed gets syntax errors when the iniial value is modified through property sheet.
Product: java Reporter: _ sandipchitale <sandipchitale>
Component: UnsupportedAssignee: Jan Becicka <jbecicka>
Status: RESOLVED FIXED    
Severity: blocker    
Priority: P2    
Version: 5.x   
Hardware: All   
OS: Windows XP   
Issue Type: DEFECT Exception Reporter:

Description _ sandipchitale 2005-11-30 18:23:54 UTC
1. Create a new application
2. Create a class and open it in editor.
3. Add a field like this:

private String foo = "fooValue";

/**
*/
public void fooMethod() {
}

4. With the cursor on foo show the Properties window. Look at the "Initial 
Value" row of properties sheet. It shows - "fooValue".

5. Now remove the value "fooValue" in property sheet and hit enter. The 
declaration changes to:

private String foo = ;

resulting in syntax error.

6. Now retype the value "barValue" in property sheet the declartion gets 
garbled even more:

private String foo = ;

/**
*/
="fooValue"public void fooMethod() {
}

7. Also if after step 5 I do an undo in the editor the property sheet is not 
updated. I have to move the cursor to some other declaration and back on foo 
to make it refresh. Possible reson is because the activated node is changed 
and back.
Comment 1 Jan Becicka 2005-12-01 08:28:21 UTC
Checking in FieldImpl.java;
/cvs/java/javacore/src/org/netbeans/modules/javacore/jmiimpl/javamodel/FieldImpl.java,v
 <--  FieldImpl.java
new revision: 1.44; previous revision: 1.43
done
Comment 2 Quality Engineering 2007-09-20 11:52:17 UTC
Reorganization of java component