Subject:
|
Re: What is exception "StackOverflowError" in method "<clinit>"
|
Newsgroups:
|
lugnet.robotics.rcx.java
|
Date:
|
Thu, 23 May 2002 12:58:25 GMT
|
Viewed:
|
4169 times
|
| |
| |
"fredsiva" <frederic.siva@wanadoo.be> writes:
>
> Yes, you are both right (Thanks anyway)
> 1. TextLCD.print() works perfectly when called from simple programs
> 2. My code is most probably using too deep calls (Why is this not covered in
> the 10/10 'Core' book of Bagnall)
>
> BUT, QUESTION FOR YOU ALL:
>
> From the following sample code,
> how can you explain that the failing instruction
> TextLCD.print(title) in menuChoice2()
> suddently works if you call another method of the same class before ?
> Is there some caching or inline code triggered in some way ?
The first time a method is called the class gets initialized,
and the stack overflow happened in the initialization method
<clinit>, so nothing mysterious there.
> While you debug my code (hey, LEGO is a game no ?), I am searching why
> another big program starts one of my motors very very slowly without me
> asking for it, I guess I am now facing a memory corruption or something like
> that.
If your program uses a lot of memory (less than 3K free)
this is a side effect of writing to memory.
Jürgen
--
Jürgen Stuber <stuber@loria.fr>
http://www.loria.fr/~stuber/
|
|
Message is in Reply To:
5 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|