Re: [Pharo-users] have a question for morphic Designer in pharo.
When trying to load Designer in Pharo 3.0 I find uncompilable code in Animations: 'updateCurrentValue: aValue self target ifNil: [^ self]. self target perform: (self property, #:) asSymbol with: aValue.'
I guess that #: should be #â:â On 27 Dec 2013, at 19:44, Stephan Eggermont <stephan@stack.nl> wrote:
When trying to load Designer in Pharo 3.0 I find uncompilable code in Animations:
'updateCurrentValue: aValue
self target ifNil: [^ self].
self target perform: (self property, #:) asSymbol with: aValue.'
On 28.12.2013, at 10:07, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
I guess that
#: should be #â:â
That is one way. In this particular case, self property asMutator was the better version, tho. Best -Tobias PS: Just curious, what was the reason to no longer allow #: ? Or, where can I find the respective discussion, just want to lern.
On 27 Dec 2013, at 19:44, Stephan Eggermont <stephan@stack.nl> wrote:
When trying to load Designer in Pharo 3.0 I find uncompilable code in Animations:
'updateCurrentValue: aValue
self target ifNil: [^ self].
self target perform: (self property, #:) asSymbol with: aValue.'
On 28 Dec 2013, at 14:24, Tobias Pape <Das.Linux@gmx.de> wrote:
On 28.12.2013, at 10:07, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
I guess that
#: should be #â:â
That is one way. In this particular case, self property asMutator was the better version, tho.
Best -Tobias PS: Just curious, what was the reason to no longer allow #: ?
I do not remember but may be this is ansi. In visualworks #âzork fooâ is the way to have symbol with string with space.
Or, where can I find the respective discussion, just want to lern.
On 27 Dec 2013, at 19:44, Stephan Eggermont <stephan@stack.nl> wrote:
When trying to load Designer in Pharo 3.0 I find uncompilable code in Animations:
'updateCurrentValue: aValue
self target ifNil: [^ self].
self target perform: (self property, #:) asSymbol with: aValue.'
On 29.12.2013, at 08:56, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
On 28 Dec 2013, at 14:24, Tobias Pape <Das.Linux@gmx.de> wrote:
On 28.12.2013, at 10:07, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
I guess that
#: should be #â:â
That is one way. In this particular case, self property asMutator was the better version, tho.
Best -Tobias PS: Just curious, what was the reason to no longer allow #: ?
I do not remember but may be this is ansi. In visualworks #âzork fooâ is the way to have symbol with string with space.
Yes, I know the #'anything' form and I am completely ok with it. I just was wondering, because things like #> #< scan directly :) Thanks anyway. Best -Tobias
On 28 Dec 2013, at 14:25, Tobias Pape <Das.Linux@gmx.de> wrote:
On 28.12.2013, at 10:07, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
I guess that
#: should be #â:â
That is one way. In this particular case, self property asMutator was the better version, tho.
Best -Tobias PS: Just curious, what was the reason to no longer allow #: ? Or, where can I find the respective discussion, just want to lern.
Pharo3 uses the new compiler infrastructure by default. This means that instead of the old (hand-written) parser, we now use RBParser (hand written, too). It seems that RBParser does not implement it. The question is who was wrong: the old parser or the new? I have no idea. But the good news is that we now just have two Parsers, not three⦠(syntax highlighting implements itâs own parser, too). What we need is a real grammar⦠that can solve these differences which come from the implementation. Another example is #9 â> both RB and the old compile it as an integer, there is special code in the Parser for that even. But do we want that? If we would have a definition of our grammar, we could look there and say âyes, itâs part of the definitionâ. Even better would be an executable grammar⦠we should explore of we can use PetitParser in the future, but there are some open questions (error handling, speedâ¦). The most beautiful would be to have just *one* parser that has a high level model of itâs grammar that is reusable everywhere. Marcus
On 30.12.2013, at 10:44, Marcus Denker <marcus.denker@inria.fr> wrote:
On 28 Dec 2013, at 14:25, Tobias Pape <Das.Linux@gmx.de> wrote:
On 28.12.2013, at 10:07, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
I guess that
#: should be #â:â
That is one way. In this particular case, self property asMutator was the better version, tho.
Best -Tobias PS: Just curious, what was the reason to no longer allow #: ? Or, where can I find the respective discussion, just want to lern.
Pharo3 uses the new compiler infrastructure by default. This means that instead of the old (hand-written) parser, we now use RBParser (hand written, too).
It seems that RBParser does not implement it. The question is who was wrong: the old parser or the new? I have no idea. But the good news is that we now just have two Parsers, not three⦠(syntax highlighting implements itâs own parser, too).
What we need is a real grammar⦠that can solve these differences which come from the implementation.
Ansi has one, but I think it is unpractical, dividing âsymbolsâ and âquoted selectorsâ :(
Another example is #9 â> both RB and the old compile it as an integer, there is special code in the Parser for that even. But do we want that? If we would have a definition of our grammar, we could look there and say âyes, itâs part of the definitionâ.
Even better would be an executable grammar⦠we should explore of we can use PetitParser in the future, but there are some open questions (error handling, speedâ¦).
The most beautiful would be to have just *one* parser that has a high level model of itâs grammar that is reusable everywhere.
Hehe. I think, both PP and Ometa would fit that criterion but I agree that this is hard-think for the core-Parser of a Smalltalk :) Best -Tobias
participants (4)
-
Marcus Denker -
Stephan Eggermont -
Stéphane Ducasse -
Tobias Pape