[Ironruby-core] Match operator

Tomas Matousek Tomas.Matousek at microsoft.com
Mon Oct 15 12:01:58 EDT 2007

We don't support regular expressions yet. Coming soon. Please, be patient.


From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of Curt Hagenlocher
Sent: Sunday, October 14, 2007 4:29 PM
To: ironruby-core at rubyforge.org
Subject: Re: [Ironruby-core] Match operator

On 10/14/07, Sanghyeon Seo <sanxiyn at gmail.com<mailto:sanxiyn at gmail.com>> wrote:
2007/10/15, Curt Hagenlocher <curt at hagenlocher.org<mailto:curt at hagenlocher.org>>:
> I don't see any evidence in
> src\IronRuby\Compiler\Parser\Parser.y that these symbol
> combinations are recognized as distinct tokens.

But the stacktrace shows Ruby.Compiler.Parser.Parse, so I assumed it's
crashing while parsing. Am I wrong?

Hmm.. I had assumed that the parser was recognizing this as <value><equals><binary negation><value>.  I was wrong, and these symbols are actually defined as MATCH and NMATCH in the grammar.  Their implementation, however, is commented out:

| arg MATCH arg
//$$ = new MatchExpression($1, $3, @$);
| arg NMATCH arg
//$$ = new NotExpression(new MatchExpression($1, $3, @$), @$);
There does not actually appear to be any implementation of the MatchExpression class.

Curt Hagenlocher
curt at hagenlocher.org<mailto:curt at hagenlocher.org>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/ironruby-core/attachments/20071015/d5bea2f1/attachment.html 

More information about the Ironruby-core mailing list