[Bug translator/20840] @defined($somethingundefined + 1) gives 1
mcermak at redhat dot com
sourceware-bugzilla@sourceware.org
Fri Apr 10 09:12:12 GMT 2026
https://sourceware.org/bugzilla/show_bug.cgi?id=20840
Martin Cermak <mcermak at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|NEW |RESOLVED
--- Comment #2 from Martin Cermak <mcermak at redhat dot com> ---
As of upstream commit 707712c62bb4c1 this is not an issue any more. Closing.
Details:
f45 x86_64 # stap --poison-cache -e 'probe
process("./a.out").function("set2") {println(@defined($x))}' -c './a.out >
/dev/null'
1
f45 x86_64 # stap --poison-cache -e 'probe
process("./a.out").function("set2") {println(@defined($nonexistent))}' -c
'./a.out > /dev/null'
0
f45 x86_64 # stap --poison-cache -e 'probe
process("./a.out").function("set2") {println(@defined($nonexistent + 1))}' -c
'./a.out > /dev/null'
WARNING: Collapsing unresolved @define to 0 [stapprobes]: operator '@defined'
at <input>:1:52
source: probe process("./a.out").function("set2")
{println(@defined($nonexistent + 1))}
^
0
f45 x86_64 # stap --poison-cache -u -e 'probe
process("./a.out").function("set2") {println(@defined($nonexistent + 1))}' -c
'./a.out > /dev/null'
WARNING: Collapsing unresolved @define to 0 [stapprobes]: operator '@defined'
at <input>:1:52
source: probe process("./a.out").function("set2")
{println(@defined($nonexistent + 1))}
^
0
f45 x86_64 #
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Systemtap
mailing list