aboutsummaryrefslogtreecommitdiff
path: root/libio/tests/tstdiomisc.exp
diff options
context:
space:
mode:
Diffstat (limited to 'libio/tests/tstdiomisc.exp')
-rw-r--r--libio/tests/tstdiomisc.exp8
1 files changed, 8 insertions, 0 deletions
diff --git a/libio/tests/tstdiomisc.exp b/libio/tests/tstdiomisc.exp
new file mode 100644
index 00000000000..b8ee02dcd6a
--- /dev/null
+++ b/libio/tests/tstdiomisc.exp
@@ -0,0 +1,8 @@
+t1: count=5
+sscanf ("12345", "%ld", &x) => 1, x = 12345
+sscanf ("12345", "%llllld", &x) => 0, x = -1
+sscanf ("12345", "%LLLLLd", &x) => 0, x = -1
+sscanf ("test ", "%*s%n", &x) => 0, x = 4
+sscanf ("test ", "%2*s%n", &x) => 0, x = -1
+sscanf ("12 ", "%l2d", &x) => 0, x = -1
+sscanf ("12 ", "%2ld", &x) => 1, x = 12