How to avoid the message "Unknown source"?

  • Follow


Before I used the option -classic with java but it is not supported anymore.

I would like to know the line where is the problem in my program.

Thanks in advance for your answer.

Richard
0
Reply grin (12) 12/10/2005 5:16:40 PM

Use -Djava.compiler=NONE
This will disable the JIT, which is the evildoer that discards
file/linenumber information.

 - Thomas

Richard wrote:
> Before I used the option -classic with java but it is not supported anymore.
>
> I would like to know the line where is the problem in my program.
> 
> Thanks in advance for your answer.
> 
> Richard

0
Reply thomas_okken (19) 12/10/2005 6:04:22 PM


Hello Thomas,

Nothing is changed with the option -Djava.compiler=NONE. My version of 
Java : 1.5.0

Richard

thomas_okken@hotmail.com a �crit :
> Use -Djava.compiler=NONE
> This will disable the JIT, which is the evildoer that discards
> file/linenumber information.
> 
>  - Thomas
> 
> Richard wrote:
> 
>>Before I used the option -classic with java but it is not supported anymore.
>>
>>I would like to know the line where is the problem in my program.
>>
>>Thanks in advance for your answer.
>>
>>Richard
> 
> 
0
Reply grin (12) 12/10/2005 9:14:22 PM

Perhaps your classes do not contain file/line information. If I
remember correctly, javac does emit this information by default, but
the Ant javac task does not. If you're using Ant, try invoking javac
using code like this:

<javac srcdir="src"
       destdir="classes"
       debug="on"
       debuglevel="source,lines"/>

If you're using the javac tool, make sure you do not have -g:none on
the command line. If no -g option is present, javac will generate file
and line number information.
Hope this helps,

 - Thomas

0
Reply thomas_okken (19) 12/11/2005 5:36:55 PM

3 Replies
49 Views

(page loaded in 0.095 seconds)

Similiar Articles:













7/17/2012 5:43:32 AM


Reply: