pike.git
/
src
/
testsuite.in
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/testsuite.in:504:
test_any([[ int a=0xffffffff; return a/17 ]], [[ (0xffffffff == -1)?-1:0x0f0f0f0f ]]); test_any([[ int a=0xffffffff; return a%17 ]], [[ (0xffffffff == -1)?16:0 ]]); test_any([[ int a=0xffffffff; return a>>17 ]], [[ (0xffffffff == -1)?-1:0x7fff ]]); dnl Check the derived return type of sprintf(). test_any([[return sprintf("%O", typeof(sprintf("%1H", "foo"))); ]],
-
"string(
0..255
)");
+
"string(
8bit
)");
test_any([[return sprintf("%O", typeof(sprintf("foo"))); ]], "string(102..111)"); test_any([[return sprintf("%O", typeof(sprintf("foo%c", 17))); ]], "string(17..17 | 102..111)"); test_any([[return sprintf("%O", typeof(sprintf("%2c\n", 'a'))); ]],
-
"string(
0..255
)");
+
"string(
8bit
)");
test_any([[return sprintf("%O", typeof(sprintf("%c", 1023))); ]], "string(1023..1023)"); test_any([[return sprintf("%O", typeof(sprintf("%c\n", 1023))); ]], "string(10..10 | 1023..1023)"); test_any([[return sprintf("%O", typeof(sprintf("%c\n", Stdio))); ]], "string"); test_any([[return sprintf("%O", typeof(sprintf("%4[1]c", 17))); ]],
-
"string(
0..255
)");
+
"string(
8bit
)");
test_any([[return sprintf("%O", typeof(sprintf("%[1]n", 17))); ]], "string(zero)"); test_any([[return sprintf("%O", typeof(aggregate("foo")));]], "array(string(102..111))"); test_any([[int a; return sprintf("%O", typeof(aggregate(a)));]], "array(int)"); test_any([[int|string a; string s = sprintf("%O", typeof(aggregate(a))); return (< "array(string) | array(int)", "array(string | int)", "array(int | string)" >)[s];]], 1); test_any([[return sprintf("%O", typeof(aggregate()));]], "array(zero)"); test_any([[int i; return (< "int", "int | zero", "zero | int" >)