1--TEST--
2Test ctype_print() function : usage variations - different integers
3--EXTENSIONS--
4ctype
5--FILE--
6<?php
7/*
8 * Pass different integers to ctype_print() to test which character codes are considered
9 * valid printable characters
10 */
11
12echo "*** Testing ctype_print() : usage variations ***\n";
13
14$orig = setlocale(LC_CTYPE, "C");
15
16for ($i = 0; $i < 256; $i++) {
17    if (ctype_print(chr($i))) {
18        echo "character code $i is a printable character\n";
19    }
20}
21
22setlocale(LC_CTYPE, $orig);
23?>
24--EXPECT--
25*** Testing ctype_print() : usage variations ***
26character code 32 is a printable character
27character code 33 is a printable character
28character code 34 is a printable character
29character code 35 is a printable character
30character code 36 is a printable character
31character code 37 is a printable character
32character code 38 is a printable character
33character code 39 is a printable character
34character code 40 is a printable character
35character code 41 is a printable character
36character code 42 is a printable character
37character code 43 is a printable character
38character code 44 is a printable character
39character code 45 is a printable character
40character code 46 is a printable character
41character code 47 is a printable character
42character code 48 is a printable character
43character code 49 is a printable character
44character code 50 is a printable character
45character code 51 is a printable character
46character code 52 is a printable character
47character code 53 is a printable character
48character code 54 is a printable character
49character code 55 is a printable character
50character code 56 is a printable character
51character code 57 is a printable character
52character code 58 is a printable character
53character code 59 is a printable character
54character code 60 is a printable character
55character code 61 is a printable character
56character code 62 is a printable character
57character code 63 is a printable character
58character code 64 is a printable character
59character code 65 is a printable character
60character code 66 is a printable character
61character code 67 is a printable character
62character code 68 is a printable character
63character code 69 is a printable character
64character code 70 is a printable character
65character code 71 is a printable character
66character code 72 is a printable character
67character code 73 is a printable character
68character code 74 is a printable character
69character code 75 is a printable character
70character code 76 is a printable character
71character code 77 is a printable character
72character code 78 is a printable character
73character code 79 is a printable character
74character code 80 is a printable character
75character code 81 is a printable character
76character code 82 is a printable character
77character code 83 is a printable character
78character code 84 is a printable character
79character code 85 is a printable character
80character code 86 is a printable character
81character code 87 is a printable character
82character code 88 is a printable character
83character code 89 is a printable character
84character code 90 is a printable character
85character code 91 is a printable character
86character code 92 is a printable character
87character code 93 is a printable character
88character code 94 is a printable character
89character code 95 is a printable character
90character code 96 is a printable character
91character code 97 is a printable character
92character code 98 is a printable character
93character code 99 is a printable character
94character code 100 is a printable character
95character code 101 is a printable character
96character code 102 is a printable character
97character code 103 is a printable character
98character code 104 is a printable character
99character code 105 is a printable character
100character code 106 is a printable character
101character code 107 is a printable character
102character code 108 is a printable character
103character code 109 is a printable character
104character code 110 is a printable character
105character code 111 is a printable character
106character code 112 is a printable character
107character code 113 is a printable character
108character code 114 is a printable character
109character code 115 is a printable character
110character code 116 is a printable character
111character code 117 is a printable character
112character code 118 is a printable character
113character code 119 is a printable character
114character code 120 is a printable character
115character code 121 is a printable character
116character code 122 is a printable character
117character code 123 is a printable character
118character code 124 is a printable character
119character code 125 is a printable character
120character code 126 is a printable character
121