-
Notifications
You must be signed in to change notification settings - Fork 86
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test for ODR-use of ::in_place_* (refs #115)
- Loading branch information
Showing
3 changed files
with
22 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,20 @@ | ||
// Copyright 2023 Peter Dimov. | ||
// Distributed under the Boost Software License, Version 1.0. | ||
// https://www.boost.org/LICENSE_1_0.txt | ||
|
||
#include <boost/system.hpp> | ||
#include <boost/core/lightweight_test.hpp> | ||
|
||
template<class T, class U> void test( T const& t, U const& u ) | ||
{ | ||
BOOST_TEST_NE( static_cast<void const*>( &t ), static_cast<void const*>( &u ) ); | ||
} | ||
|
||
int main() | ||
{ | ||
using namespace boost::system; | ||
|
||
test( result<int>::in_place_value, result<int>::in_place_error ); | ||
|
||
return boost::report_errors(); | ||
} |