* systemtap.string/dot.exp: New test.
* systemtap.string/sprint.exp: New test.
--- /dev/null
+set test "sprint"
+set ::result_string {hello
+helloworld
+12345678
+0
+100
+-42
+66
+}
+stap_run2 $srcdir/$subdir/$test.stp
--- /dev/null
+# Test of "." concatenation operator
+#
+# Use of this function is probably never a good idea
+# and is discouraged. Nevertheless, we still support it.
+
+probe begin {
+ a = "hello"
+ b = "world"
+ c = ""
+
+ x = a.b
+ y = a.b.c
+
+ print(x . "\n")
+ print(y . "\n")
+ if (x == y) print("EQUAL\n")
+ if (x == a.b) print("EQUAL\n")
+
+ z = a."-".b." ". x . " FOO " . y . "\n"
+ print(z)
+
+ exit()
+}
--- /dev/null
+set test "dot"
+set ::result_string {helloworld
+helloworld
+EQUAL
+EQUAL
+hello-world helloworld FOO helloworld
+}
+stap_run2 $srcdir/$subdir/$test.stp
--- /dev/null
+# Test of sprint() to
+#
+# Use of this function is probably never a good idea
+# and is discouraged. Nevertheless, we still support it.
+
+probe begin {
+ a = "hello"
+ b = "world"
+ c = sprint(12345678)
+ print(sprint(a) . "\n")
+ print(sprint(a.b) . "\n")
+ print(c . "\n")
+ print(sprint(0) . "\n")
+ print(sprint(100) . "\n")
+ print(sprint(-42) . "\n")
+ print(sprint(0x42) . "\n")
+
+ exit()
+}
+