Bug 301488 - [expr] Debug : Inspect gives wrong result but proceeds with correct functionality
Summary: [expr] Debug : Inspect gives wrong result but proceeds with correct functiona...
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 3.5   Edit
Hardware: PC Windows XP
: P3 minor (vote)
Target Milestone: ---   Edit
Assignee: JDT-Debug-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-02 02:13 EST by Manpreet CLA
Modified: 2022-10-08 19:25 EDT (History)
1 user (show)

See Also:


Attachments
Screenshot for the problem described (1.21 MB, image/bmp)
2010-02-15 00:48 EST, Manpreet CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Manpreet CLA 2010-02-02 02:13:43 EST
Build Identifier: M20090211-1700

public class Test {
	public static void main(String args[]){
		Integer i1=new Integer(11);
		Integer i2=new Integer(11);
		if(i1 != i2){
			System.out.println("pass");
		}else{
			System.out.println("fail");
		}
	}
}

Output of the above program should be - pass.

If we try to debug the above program and try to inspect or keep a watch on if loop expression - "i1 != i2"  it should display true as both i1 and i2 refer to two different objects, but inspect/watch displays "false" but executes proper functionality and prints "pass".

Reproducible: Always

Steps to Reproduce:
1.Debug the above given program or similar kind of code.
2.Keep a watch on expression inside if loop i.e. "i1 != i2".
3.Watch the result.
Comment 1 Manpreet CLA 2010-02-15 00:48:13 EST
Created attachment 159086 [details]
Screenshot for the problem described
Comment 2 Pawel Piech CLA 2011-06-07 19:38:49 EDT
Interesting factoid.  Not sure how important though.
Comment 3 Eclipse Genie CLA 2020-09-22 06:43:53 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 4 Eclipse Genie CLA 2022-10-08 19:25:01 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.