Live briefing
Everything about Include guard
Macro guard in C/C++ to block multiple inclusions
In the C and C++ programming languages, an #include guard, sometimes called a macro guard, header guard or file guard, is a way to avoid the problem of double inclusion when dealing with the include directive. Wikipedia →
🧭 Start here: a 6-step reading path
- Read the overview: Include guardA 5-minute orientation
- Pick up a classic book: Mao Tŝe-tung's quotationsThe most-reprinted book on the subject
- Go sideways: Pragma onceA closely related topic
- Go sideways: C preprocessorA closely related topic
📖 Definitions
Noun In C and C++, a preprocessor directive used in header files to prevent them from being included multiple times.
🗂️ The subject at a glance
🏆 Landmark papers (most cited)
- No matching papers found.
📚 Books worth reading
Mao Tŝe-tung's quotationsMao Zedong · 1962- 📕Civil War recordsKenneth Weant · 2007
- 📕Merchant Vessels of the United States... : (Including Yachts)United States Coast Guard · 2018
- 📕Coast Guard Authorization Act of 1986United States. Congress. House. Committee on Merchant Marine and Fisheries. · 1986
- 📕Coast Guard Authorization Act of 1989United States. Congress. House. Committee on Merchant Marine and Fisheries. · 1989
- 📕Coast Guard authorization, fiscal years 1983 and 1984United States. Congress. House. Committee on Merchant Marine and Fisheries. · 1982
- 📕Coast Guard authorization--fiscal year 1982United States. Congress. House. Committee on Merchant Marine and Fisheries. · 1981
- 📕Federal Protective Service Guard Contracting Reform ActUnited States. Congress. House. Committee on Transportation and Infrastructure · 2007
Ranked by number of editions on Open Library, a rough measure of how lasting a book is.
🔗 Related topics
- Pragma once In the C and C++ programming languages, #pragma once is a non-standard but widely supported preprocessor directive designed to cause the current header…
- C preprocessor The C preprocessor (CPP) is a text file processor that is used with C, C++ and other programming tools. The preprocessor provides for file inclusion (often…
- Include directive An include directive instructs a text file processor to replace the directive text with the content of a specified file. The act of including may be logical…
- Directive (programming) In computer programming, a directive or pragma (from "pragmatic") is a language construct that specifies how a compiler (or other translator) should process…
- C syntax C syntax is the form that text must have in order to be C programming language code. The language syntax rules are designed to allow for code that is terse…
- C++/CX C++/CX (or C++ Component Extensions) is a language projection for Microsoft's Windows Runtime platform. It takes the form of a language extension for C++…
- Boilerplate code In computer programming, boilerplate code, or simply boilerplate, are sections of code that are repeated in multiple places with little to no variation…
- Translation unit (programming) In C and C++ programming language terminology, a translation unit (or more casually a compilation unit) is the ultimate input to a C or C++ compiler from…