Changeset 15061


Ignore:
Timestamp:
06/09/17 08:50:44 (4 months ago)
Author:
mevenson
Message:

abcl-introspect: fix LOCAL-FUNCTION-P

(Alan Ruttenberg)

Minor improvement of any-function-name; bugfix for local-function-p.

From <https://github.com/armedbear/abcl/pull/51/commits/cc3765b9342fa8c737df80d650abc992c66b4ab6>.

Merges <https://github.com/armedbear/abcl/pull/51/>.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/contrib/abcl-introspect/abcl-introspect.lisp

    r14964 r15061  
    265265           name))))
    266266        (and (not (compiled-function-p function))
    267              `(:anonymous-interpreted-function))
     267             (let ((body (#"getBody" function)))
     268         (if (and (consp body) (consp (car body)) (eq (caar body) 'jss::invoke-restargs))
     269             `(:interpreted-function ,(concatenate 'string "#\"" (cadar body) "\""))
     270             `(:anonymous-interpreted-function))))
    268271        (function-name-by-where-loaded-from function)))))))))
    269272
     
    282285  name of the java methods"
    283286  (and (find-package :jss)
    284        (eq (type-of f) 'compiled-function)
     287       (compiled-function-p f)
    285288       (or (getf (sys::function-plist f) :jss-function)
    286289     (let ((internals (function-internal-fields f)))
     
    293296  "Helper function. Tests whether a function wasn't defined at top
    294297  level based on function-plist annotations"
    295   (and (functionp function)
     298  (and (and (functionp function) (not (typep function 'generic-function)))
    296299       (let ((plist  (sys::function-plist function)))
    297300   (or (getf plist :internal-to-function)
Note: See TracChangeset for help on using the changeset viewer.