The following method compiles with Opal:
createRedMorph
^ (self new color:Color red); yourself
but gives a syntax error with the old compilers parser
createRedMorph
^ (self new color:Color red)End of block expected -> ; yourself
removing the parenthesis of course works for both.
Who is
Interesting.
I think that for a cascade you need more than one message send.
> On 16 Sep 2015, at 10:56, Nicolai Hess wrote:
>
> The following method compiles with Opal:
>
> createRedMorph
> ^ (self new color:Color red); yourself
>
> but gives a syntax error with the old compilers parser
Nicolai,
can you try with the RBParser directly? I believe Opal uses the RBParser.
RBParser parseMethod: 'createRedMorph
^ (self new color:Color red); yourself'
Oh, RBParser sees it as:
self new
color: Color red;
yourself
:)
Thierry
2015-09-16 10:56 GMT+02:00 Nicolai Hess :
> The follow
OK, I think Sven is right and a cascade needs at least one message send
"self ; yourself"
doesn't work too (both parser don't accept this).
There are currently two methods in Pharo 5.0 with this
syntax:
DAPackageAnalyzerWindow class>>#onPackagesNamed:
DAPackageCycleDetectionTreeModel class>>#on
Arrg, sorry Yuri, this (too) isn't from QualityAssistance, but
DependencyAnalyzer
2015-09-16 15:05 GMT+02:00 Nicolai Hess :
> OK, I think Sven is right and a cascade needs at least one message send
>
> "self ; yourself"
>
> doesn't work too (both parser don't accept this).
>
> There are currently
2015-09-16 15:05 GMT+02:00 Nicolai Hess :
> OK, I think Sven is right and a cascade needs at least one message send
>
> "self ; yourself"
>
> doesn't work too (both parser don't accept this).
>
But
>
> There are currently two methods in Pharo 5.0 with this
> syntax:
>
> DAPackageAnalyzerWindow
Argh, sent too early:
self new color: Color red; yourself
est bien une cascade, non?
Thierry
2015-09-16 15:12 GMT+02:00 Thierry Goubier :
>
>
> 2015-09-16 15:05 GMT+02:00 Nicolai Hess :
>
>> OK, I think Sven is right and a cascade needs at least one message send
>>
>> "self ; yourself"
>>
>>
The PackageAnalyzer is now maintained by me (especially because it is so
usefull for the bootstrap).
I just fixed that.
Indeed, the code was wrong.
Christophe
Le 16 sept. 2015 à 15:05, Nicolai Hess a écrit :
> OK, I think Sven is right and a cascade needs at least one message send
>
> "self ;
On Wed, Sep 16, 2015 at 4:56 PM, Nicolai Hess wrote:
> The following method compiles with Opal:
>
> createRedMorph
> ^ (self new color:Color red); yourself
>
> but gives a syntax error with the old compilers parser
>
> createRedMorph
> ^ (self new color:Color red)End of block expected -> ;
On 9/16/2015 10:34 AM, Ben Coman wrote:
On Wed, Sep 16, 2015 at 4:56 PM, Nicolai Hess wrote:
The following method compiles with Opal:
createRedMorph
^ (self new color:Color red); yourself
but gives a syntax error with the old compilers parser
createRedMorph
^ (self new color:Color
2015-09-17 1:18 GMT+02:00 John Brant :
> On 9/16/2015 10:34 AM, Ben Coman wrote:
>
>> On Wed, Sep 16, 2015 at 4:56 PM, Nicolai Hess wrote:
>>
>>> The following method compiles with Opal:
>>>
>>> createRedMorph
>>> ^ (self new color:Color red); yourself
>>>
>>> but gives a syntax error with t
2015-09-16 15:14 GMT+02:00 Thierry Goubier :
> Argh, sent too early:
>
> self new color: Color red; yourself
>
> est bien une cascade, non?
>
Yes, but in
(self new color: Color red); yourself
the expression in parenthesis looks like "this evalulates first, to
'anObject' ", so we send " ; yoursel
2015-09-17 9:10 GMT+02:00 Nicolai Hess :
>
>
> 2015-09-16 15:14 GMT+02:00 Thierry Goubier :
>
>> Argh, sent too early:
>>
>> self new color: Color red; yourself
>>
>> est bien une cascade, non?
>>
>
> Yes, but in
>
> (self new color: Color red); yourself
> the expression in parenthesis looks like
> On 17 Sep 2015, at 09:32, Thierry Goubier wrote:
>
>
>
> 2015-09-17 9:10 GMT+02:00 Nicolai Hess :
>
>
> 2015-09-16 15:14 GMT+02:00 Thierry Goubier :
> Argh, sent too early:
>
> self new color: Color red; yourself
>
> est bien une cascade, non?
>
> Yes, but in
>
> (self new color: Colo
14 matches
Mail list logo