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 126581 - default value is lost if casted
Summary: default value is lost if casted
Status: VERIFIED FIXED
Alias: None
Product: uml
Classification: Unclassified
Component: Reverse Engineering (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Viktor Lapitski
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-04 03:23 UTC by Ashizawa Kazunori
Modified: 2008-03-20 18:50 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 Ashizawa Kazunori 2008-02-04 03:23:02 UTC
default value is lost if casted

Product Version: NetBeans IDE 6.0.1 (Build 200801291616)
Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b05
System: SunOS version 5.11 running on sparc; ISO646-US; en (nb)

Create a Java Application project, and add a variable with
default value like as following.

package javaapplication1;

public class Main {
    static double var = (double)100;
    public static void main(String[] args) {
    }
}

Then, create a UML Reversed Engineered Java-Platform Model
project from the above project.

Class diagram created from Main element includes attribute
"var", but its default is "(double)".  The value 100 is lost.
Comment 1 Viktor Lapitski 2008-02-20 02:05:40 UTC
Fixed.

Checking in uml/core/src/org/netbeans/modules/uml/core/reverseengineering/parsin
gfacilities/translation/expression/TypeCastExpression.java;
/cvs/uml/core/src/org/netbeans/modules/uml/core/reverseengineering/parsingfacili
ties/translation/expression/Attic/TypeCastExpression.java,v  <--  TypeCastExpres
sion.java
new revision: 1.2.6.2; previous revision: 1.2.6.1

and 

author	lvv@netbeans.org
	Tue Feb 19 17:54:48 2008 -0800 (8 minutes ago)
changeset 68293	834d9e18b1b1
parent 68273	7f9c882d140f
child 68294	fa28ea86a60f
Fix for 126581 default value is lost if casted 
Comment 2 Joanne Lau 2008-02-25 17:21:59 UTC
Fix verified in 6.1 build 200802250003
Comment 3 Karthikeyan Rajeswaran 2008-03-08 21:05:51 UTC
The fix has been ported into the release601_fixes branch.

Checking in TypeCastExpression.java;
/cvs/uml/core/src/org/netbeans/modules/uml/core/reverseengineering/parsingfacilities/translation/expression/Attic/TypeCastExpression.java,v
 <--  TypeCastExpression.java
new revision: 1.3.10.1; previous revision: 1.3
done