From: John Hughes
Subject: LISP compilation
Date: 
Message-ID: <1992May26.193124.6156@udel.edu>
I'm using Sun Common LISP 4.0. I've had the pleasure of inheriting some code 
which, when used with more inherited code, gives me a wide range of bizarre 
errors. I have finally tracked the problem down: one of the sets of code 
redefines PUSH, and the other set uses PUSH (both sets lie in independant 
packages). Finding this error was great fun, for the code which uses PUSH
works lovely IF it is compiled before the other package ever enters the 
environment. If not, it visits Never-Never land.

It appears that when one compiles a call to PUSH, one ends up with code that
circumvents the actual call, explaining my transient error. That's fine. But
I'm curious to know exactly what is going on. If I use (disassemble 'push)
I get a huge ugly mess on my SPARC station screen. If I disassemble the 
compiled call to PUSH, I get a nice little thing, which, mysteriously, exactly
resembles a disassemble of (setq x (cons x y)). How does this happen? Is the
big version of PUSH completely ignored when a compiled function calls it? Are
there two different kinds of PUSHes? Note that I compile with full-speed, full-
safety, bla bla (the default compile). 

Please reply to me directly.

John A. Hughes
A.I. duPont Institute, University of Delaware
······@asel.udel.edu
From: John Hughes
Subject: Re: LISP compilation
Date: 
Message-ID: <1992May26.200506.25078@udel.edu>
In article <·····················@udel.edu> ······@wicked.asel.udel.edu (John Hughes) writes:
[...]
>It appears that when one compiles a call to PUSH, one ends up with code that
>circumvents the actual call, explaining my transient error. That's fine. But
>I'm curious to know exactly what is going on. If I use (disassemble 'push)
>I get a huge ugly mess on my SPARC station screen. If I disassemble the 
>compiled call to PUSH, I get a nice little thing, which, mysteriously, exactly
>resembles a disassemble of (setq x (cons x y)). How does this happen? Is the
>big version of PUSH completely ignored when a compiled function calls it? Are
>there two different kinds of PUSHes? Note that I compile with full-speed, full
>safety, bla bla (the default compile). 
[...]
 Please ignore me; it's late. I just realized that push is a macro -- 
apparently one that expands to what I have above. 

John A. Hughes
······@cis.udel.edu