Hi,

At Wed, 23 Sep 2009 11:49:45 +0900,
Ryan Davis wrote in [ruby-core:25725]:
> I've looked into adding a global variable. I think it looks better,  
> but it requires modifying the parser to evaluate SOME expressions at  
> parse time and I think that is a can of worms we don't want to open.

I agree it's a worst idea.
> > +static void
> > +set_boolean(struct parser_params *parser, int *p, const char *val)
> 
> Is this really necessary? I'd rather stick to ruby values and remove  
> enable/yes/disable/no.

What do you mean by `ruby values'?

> Also, it is only being used once, so why bother abstracting it? Matz  
> is (rightfully) against using magic comments, so why enable them  
> further?

Because it seemed more readable to me at that time.

> > +    if (*str == '%') {
> > +	str++;
> > +	len--;
> > +    }
> > +    else {
> > +	if (len <= 7) return Qfalse;
> > +	if (!(beg = magic_comment_marker(str, len))) return Qfalse;
> > +	if (!(end = magic_comment_marker(beg, str + len - beg))) return  
> > Qfalse;
> > +	str = beg;
> > +	len = end - beg - 3;
> > +    }
> 
> What is this change? I don't get the '%' part. It could use a comment  
> for clarification because it isn't obvious in this area.

No matter, it was just the trace of an experiment.

-- 
Nobu Nakada