Skip to content

Commit

Permalink
variant self assignment test: suppress clang diagnostic
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreyG committed Jan 7, 2020
1 parent b16fccf commit 9e937ff
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/unit_tests/variant/variant_assign_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,9 @@ TEST_CASE("move assignment", "[variant]")

TEST_CASE("variant::operator=() - self assignment", "[variant]")
{
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wself-assign"

SECTION("self assign - empty")
{
variant a;
Expand All @@ -165,6 +168,8 @@ TEST_CASE("variant::operator=() - self assignment", "[variant]")

CHECK(a.is_valid() == true);
}

#pragma clang diagnostic pop
}

/////////////////////////////////////////////////////////////////////////////////////////

0 comments on commit 9e937ff

Please sign in to comment.