2
0
mirror of https://github.com/boostorg/nowide.git synced 2026-01-19 04:22:12 +00:00
Files
nowide/config/check_movable_fstreams.cpp
Alexander Grund a0327e0b74 Update license headers
Use the more concise format omitting the reference to the license file
and refer to the URL only.
2022-07-13 12:35:54 +02:00

18 lines
390 B
C++

//
// Copyright (c) 2020 Alexander Grund
//
// Distributed under the Boost Software License, Version 1.0.
// https://www.boost.org/LICENSE_1_0.txt
#include <fstream>
#include <utility>
/// Check that the stdlib supports swapping and moving fstreams
/// (and by extension all other streams and streambufs)
void check()
{
std::fstream s1, s2;
s1.swap(s2);
s2 = std::move(s1);
}