[IronPython] Console and comment line 0.9.6

Martin Maly Martin.Maly at microsoft.com
Wed Dec 14 09:02:30 PST 2005


As for the code changes, the console interactive loop is not perfect yet and we will improve it to handle more common cases.

The change to make comment a token is only for the tokenizer in the 'verbatim' mode, which is only when used by the Visual Studio colorizer. Otherwise the tokenizer simply ignores the comments.


-----Original Message-----
From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Stute, Detlef ALRT/EEG4
Sent: Wednesday, December 14, 2005 12:16 AM
To: users at lists.ironpython.com
Subject: [IronPython] Console and comment line 0.9.6

Hi all,
I'm using IronPython 0.9.6 as scripting engine.
I redirect the Iconsole to my own ReadLine and so on. In my ReadLine I read a file and transfer it line by line to the scripting engine. It was working with version 0.9.3 To make a long story short:
When the file includes a comment line ( like "# this is a comment"), the console only answers for the future with "...".
The same occurred, on IronPythonConsole.exe when you enter a line starting with '#' .

... More code

I added a break from the loop when ParseText returns null.
Is that the right way?
I found that the difference between 0.9.3 and 0.9.6 is that the comment is now a token ( TokenKind.cs).

More information about the users mailing list