[Newcompiler] SmaCC question -- does Test pane work forSqueakParser/SqueakScanner?

Doug Way dway at mailcan.com
Tue Oct 31 05:38:34 UTC 2006


Ah, thanks Andy & Mathieu, that worked.  Makes sense... I had noted  
earlier that the DoIt parsing was treated as a special case of the  
more general method parsing, but then I forgot about that while  
playing with the Test pane.

- Doug


On Oct 30, 2006, at 3:49 AM, Andrew Tween wrote:

> Hi Doug,
> It is trying to parse a method (rather than an expression).
> So enter, for example,
>
>     test ^3 + 4
>
> in the test pane, and it should parse ok.
> Cheers,
> Andy
>
> ----- Original Message -----
> From: "Doug Way" <dway at mailcan.com>
> To: "The New Compiler, AST, IRBuilder,Closures..."
> <newcompiler at lists.squeakfoundation.org>
> Sent: Monday, October 30, 2006 3:06 AM
> Subject: [Newcompiler] SmaCC question -- does Test pane work
> forSqueakParser/SqueakScanner?
>
>
>> Hi all.  I'm playing around with the NewCompiler, mainly just at the
>> AST level, with SmaCC (Dev), and trying to fiddle with alternate
>> syntaxes.
>>
>> Question:  I went through the SmaCC tutorial successfully.  However,
>> if I try to load the NewCompiler (SqueakScanner/SqueakParser) classes
>> into SmaCC and use the "Test" pane to test the parsing (for example
>> "3 + 4"), I always get a parsing error (Token not expected).  Same
>> with some of the other parsers such as the JavaParser.  However, the
>> Test pane parsing works for the simple CalculatorParser from the
>> tutorial.
>>
>> Any ideas?  It will be kind of a pain to play around with SmaCC if I
>> can't use the Test pane to test the changes.
>>
>> Steps to reproduce:
>> - Start up a fresh Squeak3.9-RC3-7066 image
>> - Open SqueakMap & install in this order:
>>    - Refactoring Engine v 20
>>    - SmaCCDev v 5  (from squeaksource)
>>    - AST v 88
>>    - NewCompiler v 117
>> - In SmaCC window, follow the first part of the tutorial and create
>> the CalculatorScanner/Parser
>> - In the Test tab, enter "3 + 4" and Parse... this parses  
>> successfully
>> - Back in the Compile tab, select SqueakScanner/Parser classes (or
>> JavaScanner/Parser)
>> - In the Test tab, enter "3 + 4" and Parse... error:
>> "SmaCCParserError: Token not expected->"
>>
>>
>> - Doug
>>
>> p.s. On a separate note, Goran gave me co-maintainer access to the
>> "SqueakMap2 base" package, and I've published a new version (1.23)
>> which fixes a bunch of display problems in the SqueakMap package  
>> loader.
>>
>>
>



More information about the Newcompiler mailing list