diff options
author | mmentovai <mmentovai@955884f1-7149-0410-9467-59e7ac3f4d80> | 2010-08-10 18:40:41 +0000 |
---|---|---|
committer | mmentovai <mmentovai@955884f1-7149-0410-9467-59e7ac3f4d80> | 2010-08-10 18:40:41 +0000 |
commit | b729e3cfe3d79b5153d09f5d1bd6f8aad18d82d5 (patch) | |
tree | 364d66ce9cbfe092142cfdd0f5826ec45d028c73 /cppguide.xml | |
parent | b6870cb5db3d6e2edfa0cb2998d2aa4b58b4ac69 (diff) | |
download | google-styleguide-b729e3cfe3d79b5153d09f5d1bd6f8aad18d82d5.tar.gz |
Update C++ style guide to 3.171:
- Add a section to specify deprecation comments.
Diffstat (limited to 'cppguide.xml')
-rw-r--r-- | cppguide.xml | 41 |
1 files changed, 39 insertions, 2 deletions
diff --git a/cppguide.xml b/cppguide.xml index 28b54f5..2ef0f43 100644 --- a/cppguide.xml +++ b/cppguide.xml @@ -4,7 +4,7 @@ <p align="right"> -Revision 3.170 +Revision 3.171 </p> @@ -3477,6 +3477,43 @@ Tashana Landray </BODY> </STYLEPOINT> + <STYLEPOINT title="Deprecation Comments"> + <SUMMARY> + Mark deprecated interface points with <code>DEPRECATED</code> comments. + </SUMMARY> + <BODY> + <p> + You can mark an interface as deprecated by writing a comment containing + the word <code>DEPRECATED</code> in all caps. The comment goes either + before the declaration of the interface or on the same line as the + declaration. + </p> + + <p> + After the word <code>DEPRECATED</code>, write your name, e-mail address, + or other identifier in parentheses. + </p> + <p> + A deprecation comment must include simple, clear directions for people to + fix their callsites. In C++, you can implement a deprecated function as + an inline function that calls the new interface point. + </p> + <p> + Marking an interface point <code>DEPRECATED</code> will not magically + cause any callsites to change. If you want people to actually stop using + the deprecated facility, you will have to fix the callsites yourself or + recruit a crew to help you. + </p> + <p> + New code should not contain calls to deprecated interface points. Use + the new interface point instead. If you cannot understand the + directions, find the person who created the deprecation and ask them for + help using the new interface point. + </p> + + </BODY> + </STYLEPOINT> + </CATEGORY> <CATEGORY title="Formatting"> @@ -4514,7 +4551,7 @@ Tashana Landray <HR/> <p align="right"> -Revision 3.170 +Revision 3.171 </p> |