On Feb 12, 4:20 pm, Bob Kerns r...@acm.org wrote:
However, your test case isn't one that I would expect to reproduce.
Instead of throw new ArithmeticException(), which isn't really any
different from cases I know to work, try the OP's case:
int b = 0;
int a = 1/b;
On Feb 11, 12:09 am, Bob Kerns r...@acm.org wrote:
I was catching all caught and uncaught RuntimeExceptions.
ArithmeticException is a subclass of RuntimeException, so it SHOULD
have stopped at the point of the throw.
I wrote a simple test:
public static void testThrow() {
try {
Two other thoughts:
(1) I've seen Eclipse display the exception defined by the Android
classes and the exception defined by some other VM (either its own or
whatever JDK is configured). Make sure you've got the right source
for the exception. Since ArithmeticException is working for you I'm
Thanks for the jdwpspy suggestion; I'll collect some more data when I
get a chance. Debugging-the-debugger is just my cup of tea, though
normally I have the sources at hand. (Grabbing the full Android
sources is on my to-do list).
However, your test case isn't one that I would expect to
I meant to reply to this earlier.
I've seen this before as well, long before Android. So it was one of
the first things I checked; I initially expect it to be the problem!
As you surmised, I had the right one.
On Feb 12, 3:11 pm, fadden fad...@android.com wrote:
(1) I've seen Eclipse display
All supposedly true.
I was catching all caught and uncaught RuntimeExceptions.
ArithmeticException is a subclass of RuntimeException, so it SHOULD
have stopped at the point of the throw.
It did not. It stopped later, when a RuntimeException was thrown with
the original ArithmeticException as its
On Feb 9, 7:09 pm, Bob Kerns r...@acm.org wrote:
You may not be seeing what you want because you stop too soon, before
it's really created the exception.
The debugger stops at the point of the throw. There is no exception
variable to examine because there's no exception variable in the
source
If you are in the debugger, either at a breakpoint or having stepped
over some code that justs threw an exception, I have yet to see a case
where, after stepping through using the Step Over button, you don't
eventually come to a frame that has the exception in it.
You can then use the Display
Thanks Bob,
the problem for me is that even I add a Exception breakpoint, and the
when the BP is hit, I still cannot get more information from it, there
is no ex variable I can evaluate. if you want to know what I mean, try
the following code in onCreate of an Activity class:
public void
@Bob I don't think you really nailed the problem. I ran into what I think is
a similar issue. The stack trace showed the location of the throw deep in
the Android API, without a hint of a stack frame from my code. I suppose the
problem is because some of the Android code runs in different threads,
Frank, could this be the little snag I just encountered in replying to
RustingInSeattle? Where it doesn't catch RuntimeExceptions thrown from
the low level (or maybe any level), unless there's an exact match of
class?
Can you try your scenario again, this time once you identify the
exception
11 matches
Mail list logo