SmaCC UI Problem solved but only when breakpoint was added

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

SmaCC UI Problem solved but only when breakpoint was added

Federico.Balaguer
Hello

I am progressing with my use of SmaCC and I think a found the source of the
problem that makes it impossible to generete the classes for the parser and
scanner.

Scenario
1)  I gave the name for both classes: the parser and the scanner.
2) I copy the very simple first part of the tutorial
3) I clicked on the Compile LR(1) button and a window popped up with the
label: "Both classes are not specified"

Problem:
At the time the method SmaCCDevelopmentUI>>compile: was invoked the
expression self parserClassString returns an empty string (although I
entered the name of a class on the UI)
 I found that the "parserClassMorph" did not hold the name of the class

Then I breakpointed the method SmaCCDevelopmentUI>>addParseClass: and I
entered a new name for the class of my parser and I follow with the debugger
the execution that follows the invocation of the method. Everything works as
expected.

I changed the name again but the method SmaCCDevelopmentUI>>addParseClass:
(the one with a breakpoint) was not called again.

I think it is a problem related to Morph . I am a complete ignorant on Morph
(among other things) so it is hard for me to fix the problem.

I hope this message helps fix the issue

Federico



--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html

Reply | Threaded
Open this post in threaded view
|

Re: SmaCC UI Problem solved but only when breakpoint was added

Thierry Goubier
Hi Frederico,

I think what is happening is one needs to accept (press return) in the scanner and parser test fields, for the names to be taken into account. Otherwise, they keep that non-accepted status (the orange triangle appearing in top-right of the text fields). Can you check if it was the case?

I will see to add either a warning or a way to trigger an accept (or an auto-accept) on those text fields.

Regards,

Thierry




2017-11-10 13:09 GMT+01:00 Federico.Balaguer <[hidden email]>:
Hello

I am progressing with my use of SmaCC and I think a found the source of the
problem that makes it impossible to generete the classes for the parser and
scanner.

Scenario
1)  I gave the name for both classes: the parser and the scanner.
2) I copy the very simple first part of the tutorial
3) I clicked on the Compile LR(1) button and a window popped up with the
label: "Both classes are not specified"

Problem:
At the time the method SmaCCDevelopmentUI>>compile: was invoked the
expression self parserClassString returns an empty string (although I
entered the name of a class on the UI)
 I found that the "parserClassMorph" did not hold the name of the class

Then I breakpointed the method SmaCCDevelopmentUI>>addParseClass: and I
entered a new name for the class of my parser and I follow with the debugger
the execution that follows the invocation of the method. Everything works as
expected.

I changed the name again but the method SmaCCDevelopmentUI>>addParseClass:
(the one with a breakpoint) was not called again.

I think it is a problem related to Morph . I am a complete ignorant on Morph
(among other things) so it is hard for me to fix the problem.

I hope this message helps fix the issue

Federico



--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html


Reply | Threaded
Open this post in threaded view
|

Re: SmaCC UI Problem solved but only when breakpoint was added

Federico.Balaguer
Hi Thierry,

you are right. I didn't see the orange corner at all until you pointed it
out to me.

Thanks!



--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html