James Edward Gray II <james / grayproductions.net> wrote:
> On Dec 16, 2005, at 10:36 AM, Paul Battley wrote:
> 
> >> So I'm going to write an end matching program. Could somebody please
> >> list all the keywords that are ended by "end"? Do any of these
> >> keywords ever not end in "end"?
> >
> > One wrinkle: 'do' does not always end in 'end'.  It can be a method,
> > and is used as such in DBI (e.g. 'dbh.do(...)').  It should be easy
> > enough to handle that case by checking for a preceding period,
> > however.
> 
> I imagine all the words in that list have the same issue.
> 
> Checking for the period is a good start, but watch out for edge cases:
> 
>    send(:do, *args)

Would probablly be better to check for everything that *can* precede the
'do' and have it be a real end-ended do.

martin