[squeak-dev] The Trunk: Compiler-nice.457.mcz

Marcel Taeumel marcel.taeumel at hpi.de
Mon Apr 19 14:58:44 UTC 2021


> So this is worth a mention in the release note.
Done. https://github.com/squeak-smalltalk/squeak-app/blob/squeak-trunk/release-notes/6.0 [https://github.com/squeak-smalltalk/squeak-app/blob/squeak-trunk/release-notes/6.0]

Best,
Marcel
Am 19.04.2021 15:09:43 schrieb Thiede, Christoph <christoph.thiede at student.hpi.uni-potsdam.de>:
Hi Nicolas,

Squeak 5.3 has Compiler-eem.416 and "resume: source". So this is worth a mention in the release note.

Best,
Christoph
Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von Nicolas Cellier <nicolas.cellier.aka.nice at gmail.com>
Gesendet: Montag, 19. April 2021 14:29:34
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] The Trunk: Compiler-nice.457.mcz
 
Hi Christoph,
given that resume: was a recent addition, i don't think that we must
care too much.
https://source.squeak.org/trunk/Compiler-ct.405.diff [https://source.squeak.org/trunk/Compiler-ct.405.diff]
Maybe we released Squeak 5.3 since?
In this case, it MUST at least be in the release notes indeed.


Le lun. 19 avr. 2021 à 13:11, Thiede, Christoph
<Christoph.Thiede at student.hpi.uni-potsdam.de> a écrit :
>
> Hi Nicolas,
>
>
> the renaming is a breaking change. We should make sure to document such changes in the changelog for the next release.
>
>
> Best,
> Christoph
> ________________________________
> Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von commits at source.squeak.org <commits at source.squeak.org>
> Gesendet: Freitag, 16. April 2021 22:19:40
> An: squeak-dev at lists.squeakfoundation.org; packages at lists.squeakfoundation.org
> Betreff: [squeak-dev] The Trunk: Compiler-nice.457.mcz
>
> Nicolas Cellier uploaded a new version of Compiler to project The Trunk:
> http://source.squeak.org/trunk/Compiler-nice.457.mcz [http://source.squeak.org/trunk/Compiler-nice.457.mcz]
>
> ==================== Summary ====================
>
> Name: Compiler-nice.457
> Author: nice
> Time: 16 April 2021, 10:19:30.223501 pm
> UUID: e2ce8f47-9ed2-0d46-aca1-1dd90ebed4b4
> Ancestors: Compiler-nice.456
>
> Rename resume: source -> retryWithNewSource: source.
>
> The purpose of such exception handling is indeed to retry the compilation with new source.
>
> The purpose of resume: anObject is to return anObject to the context that sent signal, that's a slightly different semantic.
>
> It happens that if we resume after setting newSource, the signaller (Parser>>notify:at:) will effectively then tryNewSourceIfAvailable.
> So effectively, resuming will end up in retrying (if there is a handler of ReparseAfterSourceEditing up the sender stack, but the Parser normally puts one).
>
> But, even if this is HOW we implement the #retryWithNewSource:,
> this is not WHAT we wish to ask to the SyntaxErrorNotification.
> in other words, we shouldn't let the implementation leak in the semantics, otherwise we put the burden of understanding the implementation on the shoulders of programmers, when they could just have trusted the semantics of pseudo natural language offered by keywords.
>
> While at it, remove the accessors of newSource.
> They are not used and may be considered private.
> This will reduce the unecessary polymorphism.
>
> =============== Diff against Compiler-nice.456 ===============
>
> Item was removed:
> - ----- Method: SyntaxErrorNotification>>newSource (in category 'accessing') -----
> - newSource
> -        ^newSource!
>
> Item was removed:
> - ----- Method: SyntaxErrorNotification>>newSource: (in category 'accessing') -----
> - newSource: aTextOrString
> -        newSource := aTextOrString!
>
> Item was removed:
> - ----- Method: SyntaxErrorNotification>>resume: (in category 'accessing') -----
> - resume: source
> -
> -        self reparse: source notifying: nil ifFail: nil.
> -        ^ super resume: self defaultResumeValue!
>
> Item was added:
> + ----- Method: SyntaxErrorNotification>>retryWithNewSource: (in category 'handling') -----
> + retryWithNewSource: source
> +        "Retry the compilation with new source code.
> +        Assume
> +        - that the signallerContext will tryNewSourceIfAvailable
> +        - the presence of a handler of ReparseAfterSourceEditing on the sender stack"
> +
> +        newSource := source.
> +        ^ self resume!
>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20210419/a9501f28/attachment.html>


More information about the Squeak-dev mailing list