marcoheisig / fast-generic-functions

Seal your generic functions for an extra boost in performance.
MIT License
94 stars 5 forks source link

Doesn't work on ECL #12

Open Gleefre opened 12 months ago

Gleefre commented 12 months ago

Following example from README:

ECL is free software, and you are welcome to redistribute it
under certain conditions; see file 'Copyright' for details.
Type :h for Help.  
Top level in: #<process TOP-LEVEL 0x7fd161c1df00>.
> (ql:quickload :fast-generic-functions)
To load "fast-generic-functions":
  Load 1 ASDF system:
    fast-generic-functions
; Loading "fast-generic-functions"

(:FAST-GENERIC-FUNCTIONS)
> (defgeneric generic-find (item sequence &key test)
    (:generic-function-class fast-generic-functions:fast-generic-function))

#<fast-generic-function GENERIC-FIND>
> (defmethod generic-find (item (list list) &key (test #'eql))
    (and (member item list :test test)
         t))

Condition of type: TYPE-ERROR
#<The STANDARD-CLASS FAST-GENERIC-FUNCTIONS:FAST-METHOD> is not of type SEQUENCE.

Available restarts:

1. (RESTART-TOPLEVEL) Go back to Top-Level REPL.

Broken at ADD-METHOD. In: #<process TOP-LEVEL 0x7fd161c1df00>.
>>