[metapost] Re: all intersections between two paths

Hans Hagen pragma at wxs.nl
Mon Jan 17 11:09:10 CET 2005


Laurence Finston wrote:

> I _always_ try to eliminate recursion in my programs wherever possible, and it
> often is.  I haven't read your code, so I don't know whether it is in this
> case.  However, I think it would be worthwhile to consider whether you
> couldn't just put the subpaths onto an array and loop over the array until
> some condition is met.

there's nothing wrong with recursion; in tex/mp, try to use tail recursion and 
then there are no limits

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------



More information about the metapost mailing list