C and C++ lingo
# declaration vs definition
Declaration - you’re telling the compiler “there’s something with this name, and it has this type”. Example:
|
|
Definition - providing all the details. For functions it means providing function body. Example:
|
|
For more info see:
What’s the difference between declaring and defining in C and C++
# Translation unit
Take a .c
file, put in a preprocessor - you get a translation unit that is turned into an .o
file after compilation. See also
on Wikipedia.