summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-03-08 02:49:08 +0000
committerDouglas Gregor <dgregor@apple.com>2010-03-08 02:49:08 +0000
commit5abbd606200d53f68b57b770ac338c2e9a696abc (patch)
treebc73b8ec58d742e6f6df473d9fd8bd8f9e0712f2
parent516a6bc399f1f4595423e80c9d4bc687f870acd1 (diff)
Make a note for the C++0x future, when we'll have to revisit the jump-diagnostics handling for variables without initializers
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97929 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Sema/JumpDiagnostics.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Sema/JumpDiagnostics.cpp b/lib/Sema/JumpDiagnostics.cpp
index 7cf207f77a..1c761b9503 100644
--- a/lib/Sema/JumpDiagnostics.cpp
+++ b/lib/Sema/JumpDiagnostics.cpp
@@ -85,6 +85,8 @@ static unsigned GetDiagForGotoScopeDecl(const Decl *D, bool isCPlusPlus) {
return diag::note_protected_by_cleanup;
if (VD->hasAttr<BlocksAttr>())
return diag::note_protected_by___block;
+ // FIXME: In C++0x, we have to check more conditions than "did we
+ // just give it an initializer?". See 6.7p3.
if (isCPlusPlus && VD->hasLocalStorage() && VD->hasInit())
return diag::note_protected_by_variable_init;