One of the great features of C is that it allows us to control the details of the program. C's memory management system is an example of this control capability. It implements these controls by letting us decide which functions know which variables and how long a variable exists in the program.
1. Storage classes and their descriptors
The main definition: scope, link, and storage time. Other programming languages also have similar concepts. The C language defines 5 storage classes through these three concepts. The specifiers are auto, register, static, extern, and TypeDef, respectively.
2. Storage classes and functions
Functions are also divided into external and static. The keywords are extern and static. is external by default.
3.malloc () and free ()
malloc () returns array pointers and struct pointers, and so on. In general, each malloc () call corresponds to a call to free ().
Type qualifier for 4.ansic
C90 adds two properties: immutability and variability, keywords are const and volatile. C99 added another kind of restrict. The main function of volatile and restrict is to facilitate compiler optimization.
C Primer Plus Reading notes the 12th Chapter