summaryrefslogtreecommitdiffstats
path: root/testsuite/systemtap.string/dot.stp
blob: 94d9c97e70fe7a77c92349383b892d95b514426b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# 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()
}