diff options
author | Galina Kistanova <gkistanova@gmail.com> | 2017-06-15 21:01:24 +0000 |
---|---|---|
committer | Galina Kistanova <gkistanova@gmail.com> | 2017-06-15 21:01:24 +0000 |
commit | d9e35a6277096188909ecf38441e6303ce27986e (patch) | |
tree | 091ffb189096ecc999339b4f262ce5efbd547159 /unittests/Basic | |
parent | 4648a7930cdc500d2609bea73eac99886c01f21a (diff) |
Added braces to work around gcc warning in googletest: suggest explicit braces to avoid ambiguous 'else'. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@305507 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/Basic')
-rw-r--r-- | unittests/Basic/VirtualFileSystemTest.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/unittests/Basic/VirtualFileSystemTest.cpp b/unittests/Basic/VirtualFileSystemTest.cpp index 0856b17791..40add2195b 100644 --- a/unittests/Basic/VirtualFileSystemTest.cpp +++ b/unittests/Basic/VirtualFileSystemTest.cpp @@ -300,8 +300,9 @@ struct ScopedDir { EXPECT_FALSE(EC); } ~ScopedDir() { - if (Path != "") + if (Path != "") { EXPECT_FALSE(llvm::sys::fs::remove(Path.str())); + } } operator StringRef() { return Path.str(); } }; @@ -316,8 +317,9 @@ struct ScopedLink { EXPECT_FALSE(EC); } ~ScopedLink() { - if (Path != "") + if (Path != "") { EXPECT_FALSE(llvm::sys::fs::remove(Path.str())); + } } operator StringRef() { return Path.str(); } }; |