Some VW to Squeak questions

radoslav hodnicak rh at 4096.sk
Tue Jun 7 19:03:17 UTC 2005



On Tue, 7 Jun 2005, Torsten Sadowski wrote:

> Hi,
>
> I'm trying to port Jun (at least partially I need the DXF parser) to
> Squeak. I did use fileOut30 on VW and now I try to fileIn the various
> parts by commenting out offending code.
>
> That UIPainter and MenuEditor code does not work is quite clear to me. But
> could someone tell me what is wrong with
>
> request: (#jun_What_is_your_name_ >> 'What is your name?') asString
>
> which gives (#jun<-Nothing more expected

squeak normally doesn't support underscores in method names. to fix it 
change the line in Scanner>>xLetter

(type _ typeTable at: c ifAbsent: [#xLetter]) == #xLetter or: [type == 
#xDigit]]

to

(type := typeTable at: c ifAbsent: [#xLetter]) == #xLetter or: [type == 
#xDigit or: [type == #leftArrow]]]

I have to do the same for glorp port.

> Another problem is
>
> getWindow
> 	^self getView ifNil: [nil] ifNotNil: [:aView | aView topComponent]!
>
> where I get
>
> topComponen<- NotNil arg of ifNil:ifNotNil: must be a 0-argument block
> ->t]
>

you can look/adapt at the VW implementation of ifNil:ifNotNil: which 
handles both 0 and 1 argument blocks. Squeak's only handles block without 
arguments

rado



More information about the Squeak-dev mailing list