[SVN] Re: [PATCH] Ruby Grammar: Distinguish augmented assignment operator from indented here-doc
Martin Kühl
martin.kuehl at gmail.com
Wed Jan 21 17:47:15 UTC 2009
On Wed, Jan 21, 2009 at 18:43, James Gray <james at grayproductions.net> wrote:
> On Jan 21, 2009, at 10:49 AM, Martin Kühl wrote:
>
>> the Ruby grammar states that the `<<` operator and `<<-`-style
>> here-docs could always be distinguished. To augment (ha!) its
>> behaviour in this respect, I added a negative lookahead after the
>> pattern matching the `<<` operator so it could never match a `<<-`
>> here-doc.
>
> I don't think this patch is OK.
>
> <<- isn't always a heredoc. For example:
>
> >> a = [ ]
> => []
> >> a<<-1
> => [-1]
Ah, you're right, I missed that.
Martin
More information about the textmate-dev
mailing list