Quantcast
Channel: Active questions tagged html - Stack Overflow
Viewing all articles
Browse latest Browse all 67441

Rregarding an example in "function invocation and the execution stack"

$
0
0

Rregarding an example in "function invocation and the execution stack" .

function a() {
  b();
  var c;
}

function b() {
  var d;
}
a();
var d;

why isn't "var d" stored in the memory of the global execution context? I thought functions and variables that are not inside other functions were supposed to be attached to the global object in the global execution stack.


Viewing all articles
Browse latest Browse all 67441

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>