[plt-dev] coding

From: Jay McCarthy (jay.mccarthy at gmail.com)
Date: Fri May 14 10:42:01 EDT 2010

And how is the performance after the fix? Is the opaque coding worth it?

On Fri, May 14, 2010 at 8:39 AM, Matthias Felleisen
<matthias at ccs.neu.edu> wrote:
>
> On May 14, 2010, at 9:43 AM, Matthias Felleisen wrote:
>
>>
>> (define (stress-test split)
>>  (define n 20000)
>>  (define l (build-list n add1))
>>  (define _ (begin (collect-garbage) (collect-garbage)))
>>  (define x
>>   (time
>>    (for/list ((i (in-range n)))
>>      (define-values (x y) (split-at-right l i))
>>      (length y))))
>>  (void))
>
>
> Sam pointed out my crucial error: when you abstract, use check syntax. (In
> case you can't see it, there's a hard-linked call to split-at-right not the
> parameter split.)_________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-dev
>



-- 
Jay McCarthy <jay at cs.byu.edu>
Assistant Professor / Brigham Young University
http://teammccarthy.org/jay

"The glory of God is Intelligence" - D&C 93


Posted on the dev mailing list.