]> sourceware.org Git - systemtap.git/commitdiff
Explicitly set the return type for __stack_raw() and __ustack_raw().
authorMartin Cermak <mcermak@redhat.com>
Fri, 2 Oct 2015 14:48:54 +0000 (16:48 +0200)
committerMartin Cermak <mcermak@redhat.com>
Fri, 2 Oct 2015 14:48:54 +0000 (16:48 +0200)
Missing return type defs may cause "unresolved type" error when
calling a function without enough context for type inference to work
like e.g. `stap -e 'probe oneshot{println(__stack_raw(0))}'`.

tapset/linux/context-symbols.stp
tapset/linux/ucontext-symbols.stp

index 32cbc87ee5cae873baa087eadf992678517ab85d..f821d3453858a204983c623893f5dd3184bcfb8d 100644 (file)
@@ -12,7 +12,7 @@
 //processor.
 // </tapsetdescription>
 
-function __stack_raw (n:long) %{ /* pragma:unwind */ /* pure */
+function __stack_raw:long (n:long) %{ /* pragma:unwind */ /* pure */
          /* basic sanity check for bounds: */
          if (unlikely(STAP_ARG_n < 0 || STAP_ARG_n >= MAXBACKTRACE))
                   STAP_RETVALUE = 0;
index c04b49984644334a3ecfd217030881a727b1b168..1b04ecd3d59366c0a350173534d4774103033724 100644 (file)
@@ -13,7 +13,7 @@
 // the function symbol of an address.
 // </tapsetdescription>
 
-function __ustack_raw (n:long) %{ /* pragma:unwind */ /* pure */ /* myproc-unprivileged */
+function __ustack_raw:long (n:long) %{ /* pragma:unwind */ /* pure */ /* myproc-unprivileged */
          /* basic sanity check for bounds: */
          if (unlikely(STAP_ARG_n < 0 || STAP_ARG_n >= MAXBACKTRACE))
                   STAP_RETVALUE = 0;
This page took 0.027685 seconds and 5 git commands to generate.