Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jdt-debug-dev] jdt debugger: Locate sources: a bug ?!


How did you instantiate the class Foo? The class is a non-public type, only visible from with in the Fooo compilation unit.

If I use this example, I can debug and see source as expected. Please file a bug if you have a reproduceable test case where this does not work.

package com.sample.program;

import java.util.Vector;

class Fooo {
        public static void main(String[] args) {
                new Foo().isEmpty();
        }
}

class Foo
{
    private Vector vec;

    Foo() {
        vec = new Vector();
    }

    boolean isEmpty() {
        return vec.isEmpty();
    }
}

Darin



Xiangmin Wang <wangxi@xxxxxxxxxx>
Sent by: jdt-debug-dev-admin@xxxxxxxxxxx

09/03/2003 05:52 PM
Please respond to jdt-debug-dev

       
        To:        jdt-debug-dev@xxxxxxxxxxx
        cc:        
        Subject:        [jdt-debug-dev] jdt debugger: Locate sources: a bug ?!




Hi,


       I have created a sample Java program to demonstrate my question. This sample is included at the end of this message.


       The issue is:  the source file name Fooo.java vs. the class name Foo (the class file name Foo.class).
 
       I think these namings are conforming to the Java Language standard. And this sample program has been compiled, run, and debugged on both Sun JDK 1.3 and MS J++ fine.


       But when I traced this  program through the eclipse debugger, I got a message that the source for Foo could not be found (actually, Fooo.java and Foo.class were in the same directory).


       Does a debugger locate source files through source file paths and line numbers in the debug sections of object files.


       Is this a bug or did I not set up correctly? Thanks for feedback.


Xiangmin


The sameple program:


// File Name: Fooo.java


package com.sample.program;


import java.util.Vector;


class Foo

{

   private Vector vec;


   Foo() {

       vec = new Vector();

   }


   boolean isEmpty() {

        return vec.isEmpty();
   }

}




Back to the top