C Primer Plus (5th Edition) by Prata Stephen

C Primer Plus (5th Edition) by Prata Stephen

Author:Prata, Stephen [Prata, Stephen]
Language: eng
Format: epub
Publisher: QUE
Published: 2004-11-22T16:00:00+00:00


If only extern is omitted from the declaration inside a function, a separate automatic variable is set up. That is, replacing

extern int Errupt;

with

int Errupt;

in main() causes the compiler to create an automatic variable named Errupt. It would be a separate, local variable, distinct from the original Errupt. The local variable would be in scope while the program executes main(), but the external Errupt would be in scope for other functions, such as next(), in the same file. In short, a variable in block scope “hides” a variable of the same name in file scope while the program executes statements in the block.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.