If I owe you an email, please bear with me. In my quotidian chainsaw-juggling, today and the next couple of days will concentrate on getting a working text of the paper I’ll be delivering at the end of the month to the Society of Biblical Literature meeting in Atlanta.
I hate being rude about late responses to email, I really do; but I can’t do everything all at once.
Posted by AKMA at November 2, 2003 08:55 PM | TrackBackBeen out of touch too long, I guess. Just wanted to add my belated congratulations. Good for you and for Seabury.
Posted by: The Happy Tutor at November 2, 2003 09:20 PMThis back and forth is an important concept to understand in C programming, especially on the Mac's RISC architecture. Almost every variable you work with can be represented in 32 bits of memory: thirty-two 1s and 0s define the data that a simple variable can hold. There are exceptions, like on the new 64-bit G5s and in the 128-bit world of AltiVec
Posted by: Sybil at January 12, 2004 07:21 PMWe can see an example of this in our code we've written so far. In each function's block, we declare variables that hold our data. When each function ends, the variables within are disposed of, and the space they were using is given back to the computer to use. The variables live in the blocks of conditionals and loops we write, but they don't cascade into functions we call, because those aren't sub-blocks, but different sections of code entirely. Every variable we've written has a well-defined lifetime of one function.
Posted by: Beatrice at January 12, 2004 07:21 PMEach Stack Frame represents a function. The bottom frame is always the main function, and the frames above it are the other functions that main calls. At any given time, the stack can show you the path your code has taken to get to where it is. The top frame represents the function the code is currently executing, and the frame below it is the function that called the current function, and the frame below that represents the function that called the function that called the current function, and so on all the way down to main, which is the starting point of any C program.
Posted by: Blaise at January 12, 2004 07:21 PMWe can see an example of this in our code we've written so far. In each function's block, we declare variables that hold our data. When each function ends, the variables within are disposed of, and the space they were using is given back to the computer to use. The variables live in the blocks of conditionals and loops we write, but they don't cascade into functions we call, because those aren't sub-blocks, but different sections of code entirely. Every variable we've written has a well-defined lifetime of one function.
Posted by: Helegor at January 13, 2004 09:38 AMBut some variables are immortal. These variables are declared outside of blocks, outside of functions. Since they don't have a block to exist in they are called global variables (as opposed to local variables), because they exist in all blocks, everywhere, and they never go out of scope. Although powerful, these kinds of variables are generally frowned upon because they encourage bad program design.
Posted by: Ninion at January 13, 2004 09:38 AMThis code should compile and run just fine, and you should see no changes in how the program works. So why did we do all of that?
Posted by: Holland at January 13, 2004 09:38 AM