1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 // <ios>
10 
11 // bool sync_with_stdio(bool sync = true);
12 
13 #include <ios>
14 #include <cassert>
15 
16 #include "test_macros.h"
17 
main(int,char **)18 int main(int, char**)
19 {
20     assert( std::ios_base::sync_with_stdio(false));
21     assert(!std::ios_base::sync_with_stdio(false));
22     assert(!std::ios_base::sync_with_stdio(true));
23     assert( std::ios_base::sync_with_stdio(true));
24     assert( std::ios_base::sync_with_stdio());
25     assert( std::ios_base::sync_with_stdio(false));
26     assert(!std::ios_base::sync_with_stdio());
27     assert( std::ios_base::sync_with_stdio());
28 
29   return 0;
30 }
31