Re: [code] Another lexer question: line comments (REAL lines comments)

From: Michael Richter <ttmrichter.att.gmail.com>
Date: Wed, 20 Nov 2013 08:51:53 +0800

On 20 November 2013 00:17, Mitchell <m.att.foicica.com> wrote:

> How would I lex a comment that has a comment character which *MUST* start
>> in column 1?
>>
>

> Use `l.starts_line(pattern)`. See the C lexer's preproc token for an
> example.
>

I have *no* idea how I missed that while it was staring me in the face.
 Thanks, Mitchell. I'll try to learn English before pestering you again.

(While I was scanning the lexer module I read that as "start_line" and
thought it was ... something utterly different.)

-- 
"Perhaps people don't believe this, but throughout all of the discussions
of entering China our focus has really been what's best for the Chinese
people. It's not been about our revenue or profit or whatnot."
--Sergey Brin, demonstrating the emptiness of the "don't be evil" mantra.
-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Tue 19 Nov 2013 - 19:51:53 EST

This archive was generated by hypermail 2.2.0 : Wed 20 Nov 2013 - 06:27:07 EST