freenode/#sicl - IRC Chatlog
Search
13:17:28
beach
I am trying to get DEFMETHOD to work without a DEFGENERIC preceding it. Currently, I get an error from INITIALIZE-INSTANCE that the METHOD-COMBINATION keyword argument was not supplied, which is right, it wasn't.
13:17:34
beach
Reading the MOP page about initialization of generic-function metaobjects suggests that this argument must be supplied so the error is correct. Then, the entry for ENSURE-GENERIC-FUNCTION-USING-CLASS explicitly says that it passes this keyword argument on without supplying any default.
13:17:36
beach
But that can't be, because the generic dispatch on this function determines whether the generic function exists or not. If it does not exist, the method specialized to NULL is invoked. And then it would have to come up with some default value, no?
13:26:50
beach
I guess there is another possibility, namely that ENSURE-GENERIC-FUNCTION checks whether the generic function exists, but that would be silly since that is what the generic dispatch of ENSURE-GENERIC-FUNCTION-USING-CLASS does.
13:29:22
splittist
beach: where does the MOP entry say EGFUC passes :method-combination through without supplying a default?
13:31:22
Colleen
Ensure-generic-function-using-class http://metamodular.com/CLOS-MOP/ensure-generic-function-using-class.html
13:36:01
jcowan
In older systems with high-end pointer tags, it was not uncommon for fixnums to have all-zeros for positive fixnums and all-ones for negative fixnums
13:36:31
beach
OK, if I trace ENSURE-GENERIC-FUNCTION-USING-CLASS on SBCL and then type a DEFMETHOD form without a preceding DEFGENERIC form, no keyword arguments are given.
13:37:45
beach
So if the :METHOD-COMBINATION keyword argument is not supplied to ENSURE-GENERIC-FUNCTION-USING-CLASS, the method specialized to NULL must supply it. But it could be supplied, so that has to be taken into account.
16:23:56
beach
I am making progress on DEFMETHOD without preceding DEFGENERIC. It was complicated because I hadn't written the code for computing a congruent generic-function lambda list from a method lambda list.
16:23:59
beach
Also, in ADD-METHOD, I need to check whether the LAMBDA-LIST slot in the generic function is bound, and during bootstrapping none of the machinery for SLOT-BOUNDP etc. works. So I define SLOT-BOUNDP as (CONSTANTLY T) during bootstrapping, because this is the only place it is called, and the slot will always be bound.
16:32:11
beach
Because heisig had the idea of putting all the DEFGENERIC for the sequence functions in one file. So if I want to check whether I can load a sequence function using my special macro, I would have to load them all in one go if I had to execute the DEFGENERIC first.
16:37:21
beach
Time to call it a day. I'll hang around until my (admittedly small) family announces that dinner is served, which will be in the next 20 minutes or less.
16:50:20
beach
My (admittedly small) family just announced that dinner is served. I'll be back tomorrow morning as usual.
20:02:44
Harag
ac-slime does not play well with sicl repl, if autocomplete kicks in (ie popup) it freezes emacs. Is there anything I can do about it or should I just disable autocomplete in the repl?
22:10:57
Harag
scymtym: wow, what a difference from auto-complete! For one it actually looks great and keys are dont have different behaviour between repl and lisp file buffers!