diff options
author | hunt <hunt> | 2007-06-20 21:42:39 +0000 |
---|---|---|
committer | hunt <hunt> | 2007-06-20 21:42:39 +0000 |
commit | 727d33a0728a633371ce8d1e9b5a791d9c45d6fb (patch) | |
tree | efe15b0ad942f481c2290fb762ec4049aeea8a91 /testsuite/systemtap.string/sprint.stp | |
parent | 6da7f545b60445cfaa6e69896da4ee5a950cd6bb (diff) | |
download | systemtap-steved-727d33a0728a633371ce8d1e9b5a791d9c45d6fb.tar.gz systemtap-steved-727d33a0728a633371ce8d1e9b5a791d9c45d6fb.tar.xz systemtap-steved-727d33a0728a633371ce8d1e9b5a791d9c45d6fb.zip |
2007-06-20 Martin Hunt <hunt@redhat.com>
* systemtap.string/dot.exp: New test.
* systemtap.string/sprint.exp: New test.
Diffstat (limited to 'testsuite/systemtap.string/sprint.stp')
-rw-r--r-- | testsuite/systemtap.string/sprint.stp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/testsuite/systemtap.string/sprint.stp b/testsuite/systemtap.string/sprint.stp new file mode 100644 index 00000000..30f2f854 --- /dev/null +++ b/testsuite/systemtap.string/sprint.stp @@ -0,0 +1,20 @@ +# 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() +} + |