Venkman is borked? (I'm seeing strange non-JS like behavior)

"Svend Tofte" <[email protected]>
Newsgroups gmane.comp.mozilla.devel.jsdebugger
Organization http://groups.google.com
Message-ID <[email protected]>
Hey,

A while ago, I wrote a guide to Venkman, and felt I got a good workout
in it's use. However, since that time, both from readers of my guide,
and from own experience, something has been amiss with Venkman. I'm
writing here, to see if this can be cleared up, as it's frankly
perplexing to me.

A pretty standard way to start debugging in Venkman, is to load
venkman, press "stop", and reload the browser with the desired js.
However, when this is done, it seems as if the browser will first
perform a "parse" or something similar, before it does it's "usual"
thing.

Given this script:

<script>
var a = 1;
function test(a) {
    var t = "passed : ";
    return t + a;
}
var b = test(a);
document.write("<p>" + b + "</p>");
</script>

It will stop at the first line (var a = 1;), and if you then enter "a"
into the console, you get a
!! Caught exception: "ReferenceError: a is not defined"
This is not in line with my knowledge of JS. It should defined, and
hold the value of "void" (before evaluation of the line). If you then
step further on to the next line, "a" is no longer undefined, but now
holds the value of "void", which is silly, since it just passed an
assignment statement. Further problem of the same sort can be seen
throughout my guide.

And frankly, I'm lost. I downloaded the last Mozilla (1.7.12) from
mozilla.org, it came with venkman 0.9.81 (I believe), I saw the problem
there. I upgraded (via Ginda's homepage) to 0.9.85, and I am still
seeing the same behavior.

I'm 100% certain, that this was not how Venkman behaved, while I wrote
my guide. Further, this seems to be utterly perplexing to me. It seems
as if this is a rather grave error, but I'm not seeing any mention of
this anywhere.

Can someone shed some light on the issue? :)

Regards,
Svend
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.