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 | // <locale> |
10 | |
11 | // template <class charT> bool isprint (charT c, const locale& loc); |
12 | |
13 | #include <locale> |
14 | #include <cassert> |
15 | |
16 | #include "test_macros.h" |
17 | |
18 | int main(int, char**) |
19 | { |
20 | std::locale l; |
21 | assert( std::isprint(' ', l)); |
22 | assert( std::isprint('<', l)); |
23 | assert(!std::isprint('\x8', l)); |
24 | assert( std::isprint('A', l)); |
25 | assert( std::isprint('a', l)); |
26 | assert( std::isprint('z', l)); |
27 | assert( std::isprint('3', l)); |
28 | assert( std::isprint('.', l)); |
29 | assert( std::isprint('f', l)); |
30 | assert( std::isprint('9', l)); |
31 | assert( std::isprint('+', l)); |
32 | |
33 | return 0; |
34 | } |
35 | |