From: William H. N. <wil...@ai...> - 2002-04-05 18:38:40
|
On Fri, Apr 05, 2002 at 09:00:04AM +0100, Christophe Rhodes wrote: > On Thu, Apr 04, 2002 at 06:42:57PM -0600, William Harold Newman wrote: > > On Wed, Apr 03, 2002 at 06:33:03PM +0100, Christophe Rhodes wrote: > > > Attached are two things: a patch that causes sbcl to get the atom type > > > right (I believe), and a rather stream-of-consciousness ramble about > > > what I did to implement it. There were some nasty surprises along the > > > way, and the patch could probably do with review anyway as there are > > > non-obvious portions to it, and at least two portions that could do with > > > changing (the :complex-subtypep-arg2 bit marked with a FIXME, and the > > > fact that I've forgotten to export *atom-type*). > > > > Review, hmm. > > :-) I thought it might be slightly controversial; these things generally > are. I confess that I was more surprised at the fact that the typep > optimizer was necessary -- any thoughts on that? Well, it's not controversial like the arguments I've had with people about what goes into the system. Even if I get hit by a bus before I hit 'send', and spend the next few months convalescing or descending to Hell or whatever, so that in any event way my alternative proposal gets lost, I'll still be happy to have your approach merged. But still... I've attached a patch showing my alternate CALL-NEXT-METHOD-ish approach. As you can see, it's only implemented for OR types, not for FUNCTION or NUMBER types. Thus, when I copied your new regression tests, I commented out the FUNCTION-related and NUMBER-related tests to get this code to pass. But this code does pass the new OR/LIST-related tests OK, and I don't expect there will be a problem generalizing it to other type classes. So now I'll ask for review too. -- William Harold Newman <wil...@ai...> "Now it's a couple of guys sitting in a living room with laptops. (And jeans turn out not to be the last word in informality.)" -- <http://www.paulgraham.com/road.html> PGP key fingerprint 85 CE 1C BA 79 8D 51 8C B9 25 FB EE E0 C3 E5 7C |