Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ReachableCode] Skip over ExprWithCleanups in isConfigurationValue
Summary: Fixes pr29152. Reviewers: rsmith, pirama, krememek Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D24010 llvm-svn: 285657
- Loading branch information
Showing
3 changed files
with
20 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// RUN: %clang_cc1 -fsyntax-only -Wunreachable-code -verify %s | ||
|
||
static const bool False = false; | ||
|
||
struct A { | ||
~A(); | ||
operator bool(); | ||
}; | ||
void Bar(); | ||
|
||
void Foo() { | ||
if (False && A()) { | ||
Bar(); // expected-no-diagnostics | ||
} | ||
} |