summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRasmus Lerdorf <rasmus@php.net>2001-04-09 15:44:24 +0000
committerRasmus Lerdorf <rasmus@php.net>2001-04-09 15:44:24 +0000
commit334cba47b9920c5400a49e630e035ac8c52fc824 (patch)
tree65dbe7da37cec4be2d63b341070e309bc53af6d4 /tests
parent066547a220b460fcd92a9174734a4dea1f0cfb3f (diff)
downloadphp-git-334cba47b9920c5400a49e630e035ac8c52fc824.tar.gz
printf argnum (parameter swapping) support from Morten Poulsen
Diffstat (limited to 'tests')
-rw-r--r--tests/strings/002.phpt8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/strings/002.phpt b/tests/strings/002.phpt
index 50c0b35287..195d3bd5e5 100644
--- a/tests/strings/002.phpt
+++ b/tests/strings/002.phpt
@@ -34,6 +34,10 @@ printf("printf test 22:%016x\n", 170);
printf("printf test 23:%016X\n", 170);
printf("printf test 24:%.5s\n", "abcdefghij");
printf("printf test 25:%-2s\n", "gazonk");
+printf("printf test 26:%2\$d %1\$d\n", 1, 2);
+printf("printf test 27:%3\$d %d %d\n", 1, 2, 3);
+printf("printf test 28:%2\$02d %1\$2d\n", 1, 2);
+printf("printf test 29:%2\$-2d %1\$2d\n", 1, 2);
?>
--EXPECT--
@@ -64,3 +68,7 @@ printf test 22:00000000000000aa
printf test 23:00000000000000AA
printf test 24:abcde
printf test 25:gazonk
+printf test 26:2 1
+printf test 27:3 1 2
+printf test 28:02 1
+printf test 29:2 1