1- ## Module name: topic name
1+ ## Module name: Headers
22
33_ Skeleton descriptions are typeset in italic text,_
44_ so please don't remove these descriptions when editing the topic._
@@ -74,7 +74,7 @@ _This section lists important details for each point._
7474
7575#### Background/Required Knowledge
7676
77- * All of the above.
77+ * All of the above
7878* Define a function and write a separate, matching, declaration
7979* Distinguish between a declaration and a definition
8080* Compile multiple translation units and link them together into a single executable
@@ -84,22 +84,53 @@ _This section lists important details for each point._
8484A student should be able to:
8585
86861 . Create a declaration for an existing function, placed in a separate file
87- 2 . Include a header within the same directory
88- 3 . Include a header locatable within the compiler's include directories
87+ 2 . Utilize double-quote inclusion to include a header from the same directory
88+ 3 . Utilize angular-bracket inclusion to include a header from standard library
89894 . Explain the meaning of the one-definition rule and how it applies to headers
90905 . Protect a header with include guards and explain why they are necessary
9191
9292#### Caveats
9393
94- * #pragma is useful, but not standardized and so may not be fully supported on all systems
94+ * ` #pragma once ` is useful, but not standardized and so may not be fully supported on all systems
9595* Reusing the same include guards may cause confusion. Naming conventions based on file paths can help
9696* Accidentally putting a definition in a header file may or may not introduce undefined behavior
9797* Circular dependencies can cause confusion. Care should be taken in identifying such
9898*
9999
100100#### Points to cover
101101
102+ * Angular bracket inclusion goes to the system/compiler path
103+ * Double quotes inclusion uses just relative paths
104+
102105### Advanced
103106
104107_ These are important topics that are not expected to be covered but provide
105108guidance where one can continue to investigate this topic in more depth._
109+
110+ Templates in headers?
111+ Classes in headers?
112+ Macros in headers?
113+ Modules as replacement?
114+ Issues with specifying default arguments in headers?
115+
116+
117+ #### Background/Required Knowledge
118+
119+ * All of the above
120+
121+ #### Student outcomes
122+
123+ A student should be able to:
124+
125+ 1 . Utilize angular-bracket inclusion and compiler flags to include headers from non-standard paths
126+ 2 . Identify trade-offs of aggressiveness of putting declarations in a header file without known consumer
127+
128+ #### Caveats
129+
130+ _ This section mentions subtle points to understand, like anything resulting in
131+ implementation-defined, unspecified, or undefined behavior._
132+
133+ #### Points to cover
134+
135+ _ This section lists important details for each point._
136+
0 commit comments