From e5aeb8fb72cf3e2dc237fe0e40f70813e3fc321b Mon Sep 17 00:00:00 2001
From: mmentovai
Date: Wed, 12 May 2010 16:52:16 +0000
Subject: [PATCH] Update C++ style guide to 3.161: - Forbid the use of
operator synonyms such as "and." - Specify the naming convention (OrDie) to
use when a function has crash-on-failure semantics. - Allow static const
data members to be non-private. - Specify placement of friend declarations.
- Require each file to include headers that they use.
Update Objective-C style guide to 2.18:
- Prefer @optional to informal protocols when possible.
- Specify formatting for invoking methods.
- Require that -dealloc be easy to review.
---
cppguide.xml | 39 +++++++++++++++++-----
objcguide.xml | 91 ++++++++++++++++++++++++++++++++++++++++++---------
2 files changed, 107 insertions(+), 23 deletions(-)
diff --git a/cppguide.xml b/cppguide.xml
index c61416f..3df79ea 100644
--- a/cppguide.xml
+++ b/cppguide.xml
@@ -4,7 +4,7 @@
-Revision 3.154
+Revision 3.161
@@ -204,6 +204,16 @@ Tashana Landray
include several header files.
+
+ If you use a symbol Foo
in your source file, you
+ should bring in a definition for Foo
yourself,
+ either via an #include or via a forward declaration. Do not
+ depend on the symbol being brought in transitively via headers
+ not directly included. One exception is if Foo
+ is used in myfile.cc
, it's ok to #include (or
+ forward-declare) Foo
in myfile.h
,
+ instead of myfile.cc
.
+