- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Re: Re: On jump removal once again
Mon, 2011-06-13, 23:20
Sorry, I should have been more clear. I mean that gotoelim would just
leave those LabelDefs untransformed.
On Mon, Jun 13, 2011 at 3:19 PM, Grzegorz Kossakowski
wrote:
> 2011/6/14 Aaron Novstrup
>>
>> What about the option of just ignoring those LabelDefs, then, rather
>> than issuing an error? The jribble backend should be able to handle
>> labels -- it's just Apply that's the hard part, right?
>
> What do you mean by ignoring? Completely dropping the tree, including right
> hand side of LabelDef?
> --
> Grzegorz Kossakowski
>
>
Mon, 2011-06-13, 23:57
#2
Re: Re: On jump removal once again
I agree that eliminating it would be better, if it's possible. I
suggest modifying the gotoelim plugin to leave those LabelDefs
untransformed for now, and then wait to hear from Miguel about whether
such labels can, in general, be replaced with their rhs (and replacing
the label's parameters with the corresponding symbols from the
enclosing scope, if necessary).
On Mon, Jun 13, 2011 at 3:29 PM, Grzegorz Kossakowski
wrote:
> 2011/6/14 Aaron Novstrup
>>
>> Sorry, I should have been more clear. I mean that gotoelim would just
>> leave those LabelDefs untransformed.
>
>
> That would be another option but if we can get rid of them, the better.
> Jribble backend handles LabelDefs' parameters by allocating some local
> variables. Also, for each LabelDef we introduce while loop so we can use
> break/continue. Since there are no gotos, the while loop is not necessary,
> too. If we can reduce that noise I'm all for it.
> --
> Grzegorz Kossakowski
>
>
Tue, 2011-06-14, 00:07
#3
Re: Re: On jump removal once again
2011/6/14 Aaron Novstrup <aaron.novstrup@gmail.com>
--
Grzegorz Kossakowski
I agree that eliminating it would be better, if it's possible. IAh, got it now. Sounds like a good plan. Thanks.
suggest modifying the gotoelim plugin to leave those LabelDefs
untransformed for now, and then wait to hear from Miguel about whether
such labels can, in general, be replaced with their rhs (and replacing
the label's parameters with the corresponding symbols from the
enclosing scope, if necessary).
--
Grzegorz Kossakowski
Tue, 2011-06-14, 00:07
#4
Re: Re: On jump removal once again
2011/6/14 Grzegorz Kossakowski <grzegorz.kossakowski@gmail.com>
Damn, I only realized that Miguel in his original e-mail said "I've completed the first half of its implementation". The other half is actual transformation that he discusses a bit here: http://lamp.epfl.ch/~magarcia/ScalaCompilerCornerReloaded/2011Q1/JumpsRemover.pdf
Looks like I was so happy to solve forward jumps problem once and forever in my project that I didn't check basic facts...
--
Grzegorz Kossakowski
Ah, got it now. Sounds like a good plan. Thanks.
Damn, I only realized that Miguel in his original e-mail said "I've completed the first half of its implementation". The other half is actual transformation that he discusses a bit here: http://lamp.epfl.ch/~magarcia/ScalaCompilerCornerReloaded/2011Q1/JumpsRemover.pdf
Looks like I was so happy to solve forward jumps problem once and forever in my project that I didn't check basic facts...
--
Grzegorz Kossakowski
That would be another option but if we can get rid of them, the better. Jribble backend handles LabelDefs' parameters by allocating some local variables. Also, for each LabelDef we introduce while loop so we can use break/continue. Since there are no gotos, the while loop is not necessary, too. If we can reduce that noise I'm all for it.
--
Grzegorz Kossakowski