[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: survey - JAR's answers

I    1. (EQ?  (LAMBDA (X) X) (LAMBDA (Y) Y))		;"Coalescing"
E    2. (EQV? (LAMBDA (X) X) (LAMBDA (Y) Y))
I    3. (LET ((X (LAMBDA (Z) Z))) (EQ?  X X))	;"Splitting"
E    4. (LET ((X (LAMBDA (Z) Z))) (EQV? X X))
U    5. (LET ((X ... exact number ...)) (EQ? X X))
X    6. (EQ? #\X #\X)

I agree with your answers and reasons on 1-4.

5.  As I understand it, specifying that this expression returns true might
preempt certain optimizations in numerical code.  (Like not consing
intermediate results by using unboxed number representations that are not
available to the user.)  I would agree with Jonathan (with an 'I'), but I don't
feel too strongly about it, so I could be swayed.

6.  This seems the same as 5, except that characters are less likely
candidates for optimizations.  Since it doesn't affect the compiler,
and its easy to implement either (any) way, I don't care.