]> granicus.if.org Git - clang/commitdiff
Fix a gcc Wuninitialized false positive.
authorDaniel Dunbar <daniel@zuster.org>
Thu, 10 Feb 2011 18:24:25 +0000 (18:24 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Thu, 10 Feb 2011 18:24:25 +0000 (18:24 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125298 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaExpr.cpp

index fcc56f149200a035e9f8ada3d5e0c15821319a11..5634c6cdd87d2c2d83da6d22dfe6ec7cef0d0011 100644 (file)
@@ -2369,7 +2369,7 @@ Sema::BuildDeclarationNameExpr(const CXXScopeSpec &SS,
     // variable is within the block, create a normal DeclRefExpr.
 
     QualType type = VD->getType();
-    ExprValueKind valueKind;
+    ExprValueKind valueKind = 0;
 
     switch (D->getKind()) {
     // Ignore all the non-ValueDecl kinds.