This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

membership test problem


What should the following code print? I expected TRUE, but got FALSE. Looks like if the array element value is 0, the membership test fails. Is this correct?

p = pid()
t = tid()

prot_tx[p,t] = 0

if ([p,t] in prot_tx) {
	print("TRUE\n")
} else {
	print("FALSE\n")
}

- Mike


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]