<html><head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
  </head>
  <body>
    <p>Thanks so very much, Juan! It's now #green. I have attached the
      PromisesLocalCuisCompatability file and version <71> of
      PromisesLocal. I changed my call to #becomeForward: only when
      #isResolved not and changed my call from #cull: to #value:  FIle
      'em in and run the tests, as you wish. Viel spass!<br/>
    </p>
    <p><img moz-do-not-send="false" src="cid:part1.J0cA5I2U.sQrHvUa0@callistohouse.org" alt="" width="893" height="491"/></p>
    <p><br/>
    </p>
    <br/>
    <div class="moz-cite-prefix">On 6/24/23 21:23, rabbit via Cuis-dev
      wrote:<br/>
    </div>
    <blockquote type="cite" cite="mid:oEiGYYaNuu1r67zNZQB0d-JniVNEuE1H12eKfrLr_hobXgsuT75Czi_5ypYF9zHxUEoWCJtrQLfa7FtgPqDIxmVm-Mn65Z1bUMpG_yr3Pgw=@callistohouse.org">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
      <div><br/>
      </div>
      <div><br/>
      </div>
      <div class="protonmail_signature_block" id="protonmail_signature_block">
        <div>❤️‍🔥🐰</div>
      </div>
      <div class="signature_br" contenteditable="false"><br/>
      </div>
      <div class="signature_br" contenteditable="false"><br/>
      </div>
      <div><br/>
      </div>
      <div><br/>
      </div>
      On Sat, Jun 24, 2023 at 21:15, Juan Vuletich <<a class="" href="mailto:On Sat, Jun 24, 2023 at 21:15, Juan Vuletich
        <<a href=" moz-do-not-send="true">juan@cuis.st</a>>
      wrote:
      <blockquote type="cite" class="protonmail_quote">
        <title></title>
        On 6/24/2023 10:05 PM, rabbit via Cuis-dev wrote:
        <blockquote type="cite">
          <div dir="auto">Oh! That’s exactly the semantics I’m
            expecting! When the method resumes I’m absolutely expecting
            self to be the new guy. </div>
        </blockquote>
        <br/>
        And the new guy doesn't include the method you are resuming!
        Please check references to MethodInCallStackToBecomeInvalid . If
        the new guy includes the same exact method, then it makes sense
        to resume its execution. Maybe you can include that method.</blockquote>
      <div dir="auto"><br/>
      </div>
      I understand what you’re saying. I think. If the old guy and the
      new guy both use the same superclass defined CompiledMethod
      splayed on the stack, #becomeForward: should be happy? Thanks! Let
      me go check.<caret></caret><br/>
      <blockquote type="cite" class="protonmail_quote" dir="auto"> <br/>
        <blockquote type="cite">
          <div dir="auto">If a subsequent message call is not
            understood, a DNU would be raised. Can we get a parallel
            method to give me those semantics, please? Portability is
            #becomeForward: but not that breaks your existing contract.
            Could we test #isEventual in #becomeForward:, perhaps?</div>
        </blockquote>
        <br/>
        Not in Cuis base image. That programming pattern is completely
        wrong in my view. But I won't police your code, I'll just be
        very careful with the Cuis base image.</blockquote>
      No doubt! If I can help I will. Solid. Totally fault-tolerant.
      Always recoverable. Always on.
      <div dir="auto"><span style="color: var(--text-color);" dir="auto"><br/>
        </span></div>
      <div dir="auto"><span style="color: var(--text-color);" dir="auto">I’m
          thinking the method sending </span><span style="color:
          var(--text-color);">the #becomeForward: is absent in the new
          guy. Or different, perhaps. I’ll need to turn that over a few
          times. Uno</span><span style="color: var(--text-color);" dir="auto"> momento<caret></caret></span><span style="color:
          var(--text-color);">, per pia cheri!</span>
        <div dir="auto">
          <blockquote type="cite" class="protonmail_quote"> <br/>
            <blockquote type="cite">
              <div><br/>
              </div>
              <div id="protonmail_signature_block" class="protonmail_signature_block">
                <div>❤️‍🔥🐰</div>
              </div>
              <div class="signature_br" contenteditable="false"><br/>
              </div>
              <div class="signature_br" contenteditable="false"><br/>
              </div>
              <div><br/>
              </div>
              <div><br/>
              </div>
              On Sat, Jun 24, 2023 at 20:38, Juan Vuletich <<a href="mailto:On%20Sat,%20Jun%2024,%202023%20at%2020:38,%20Juan%20Vuletich%20%3C%3Ca%20href=" class="" moz-do-not-send="true">juan@cuis.st</a>>
              wrote:
              <blockquote class="protonmail_quote" type="cite">
                <title></title>
                I'm not familiar with your code.<br/>
                <br/>
                But that error message you get is real. It is not a
                problem in Cuis. It is a problem in your code. You are
                doing #becomeForward: of an object that is in the midst
                of running a method. If the become is done, that method
                will later resume running, but self will be a different
                object, maybe an object of another class, where this
                method is not defined, and can not be run.<br/>
                <br/>
                I suggest understanding this problem. It is safer to
                only do become on objects that are NOT running any
                methods at that moment.<br/>
                <br/>
                Squeak doesn't give you this error simply because Squeak
                doesn't check for this problem. A VM crash is likely in
                this situation. I actually added this check to Cuis
                after someone (it was a long time ago, I don't remember
                who it was) was experiencing VM crashes because a method
                was resumed on a becomed object, and was writing
                instance variables that didn't exist in the becomed
                object.<br/>
                <br/>
                HTH,<br/>
                <br/>
                On 6/24/2023 10:57 AM, rabbit via Cuis-dev wrote:
                <blockquote type="cite">
                  <p>Hi Juan, I'm attaching 2 squeak source files, one
                    with 2 methods in compatibility and the other the
                    source.st out of my latest
                    PromisesLocal-rabbt.66,mcz. <br/>
                  </p>
                  <p>I got the Vat's eventual process working (issues
                    with terminate), <br/>
                  </p>
                  <p>but I'm blowing up on a call to #becomeForward:,
                    from ENearPromise>>#becomeContext:, when
                    resolving a promise. Here is an image of the
                    resulting debugger. Is there more information I
                    could provide or is someone willing to attempt to
                    reproduce? Many thanks! ❤️‍🔥🐰</p>
                  <p><img src="imap://rabbit%40callistohouse%2Eorg@127.0.0.1:1143/fetch%3EUID%3E/INBOX%3E2638?header=quotebody&part=1.1.2&filename=part1.03010406.06090709@cuis.st" alt="" class="loading-internal"/></p>
                  <div class="moz-cite-prefix">On 6/23/23 20:50, rabbit
                    via Cuis-dev wrote:<br/>
                  </div>
                  <blockquote type="cite">
                    <div dir="auto">Ahh! Thanks for the reminder. That’s
                      how I started loading code a month ago or whenever
                      I was loading mczs. I’ll look into it tomorrow.</div>
                    <div dir="auto"><br/>
                    </div>
                    <div dir="auto">Is it possible to get Monticello pkg
                      loading working again? That’d be very good.</div>
                    <div dir="auto"><br/>
                    </div>
                    <div dir="auto">What’s my go to solution for code
                      packaging in Cuis? I’d like to establish Crypto in
                      Cuis.</div>
                    <div><br/>
                    </div>
                    <div class="protonmail_signature_block" id="protonmail_signature_block">
                      <div>❤️‍🔥🐰</div>
                    </div>
                    <div class="signature_br" contenteditable="false"><br/>
                    </div>
                    <div class="signature_br" contenteditable="false"><br/>
                    </div>
                    <div><br/>
                    </div>
                    <div><br/>
                    </div>
                    On Fri, Jun 23, 2023 at 19:21, Juan Vuletich via
                    Cuis-dev <<a class="" href="mailto:On%20Fri,%20Jun%2023,%202023%20at%2019:21,%20Juan%0A%20%20%20%20%20%20%20%20Vuletich%20via%20Cuis-dev%20%3C%3Ca%20href=" moz-do-not-send="true">cuis-dev@lists.cuis.st</a>>
                    wrote:
                    <blockquote type="cite" class="protonmail_quote"> Hi
                      rabbit,<br/>
                      <br/>
                      I suggest unzipping the Monticello files to
                      extract the code in plain text (yes, Monticello
                      files are just zip files). When you are there, you
                      can also fix the line ending convention of the
                      files. And of course, you'd neet to check the
                      code, because Cuis is not 100% compatible with
                      Squeak.<br/>
                      <br/>
                      We don't use Monticello in Cuis. At some point in
                      the past it was possible to open MC files in Cuis,
                      but nobody used that feature in ages and it got
                      bitrotten.<br/>
                      <br/>
                      Thanks,<br/>
                      <br/>
                      On 6/23/2023 4:00 PM, rabbit via Cuis-dev wrote:
                      <blockquote type="cite">
                        <p>I just realized I have been working in
                          squeak. I updated PromisesLocal-rabbt.66.mcz
                          and am attaching it. I am getting the error
                          below when I 'browse code' or 'install
                          Mionticello package'. I do not know. How can I
                          load Monticello packages? Any way to get the
                          Installer available in cuis? Install
                          Monticello config maps?<br/>
                        </p>
                        <p>I appreciate you,<br/>
                          rabbit</p>
                        <p><img alt="" class="loading-internal" moz-do-not-send="true" width="862" height="398"/></p>
                        <p><br/>
                        </p>
                        <div class="moz-cite-prefix">On 6/22/23 16:21,
                          rabbit via Cuis-dev wrote:<br/>
                        </div>
                        <blockquote type="cite">
                          <p>Hey! I got inspired by your proposal,
                            Luciano, and here's my solution in eventual
                            promises. Code can be loaded as:</p>
                          <blockquote>
                            <p>Installer ss project: 'Cryptography';
                              install: 'ProCrypto.release.3'.<br/>
                            </p>
                          </blockquote>
                          <p>I added a test method <br/>
                          </p>
                          <blockquote>
                            <p>RefsTest>>#testMultiReturns<br/>
                              <br/>
                              | selectCount unionFlag pair |<br/>
                              unionFlag := false.<br/>
                              selectCount := 0.<br/>
                              ((pair := self promiseResolverPair) key
                              xgcd: 9) <br/>
                              <<* [:each | selectCount :=
                              selectCount + 1. Transcript cr; show:
                              'each = ', each];<br/>
                              <<* [:g :s :t | unionFlag := true.
                              Transcript cr; show: 'g = ', g, '; s = ',
                              s, '; t = ', t. g + s + t].<br/>
                              pair value resolve: 21.<br/>
                              (Delay forMilliseconds: 333) wait.<br/>
                              self assert: (selectCount == 3).<br/>
                              self assert: (unionFlag).</p>
                          </blockquote>
                          <p>This calls new multireturn #xgcd: method</p>
                          <blockquote>
                            <p>xgcd: anInteger<br/>
                              " 21 xgcd: 9"<br/>
                              | g s t |<br/>
                              g := self gcd: anInteger.<br/>
                              s := self / g.<br/>
                              t := anInteger / g.<br/>
                              ^ { g. s. t}<br/>
                            </p>
                          </blockquote>
                          <p>And in the test method there are eventual
                            sends (#<<*) to the promise of the
                            #xgcd: send once the reciever promise is
                            resolved to 21. This implementation detects
                            cardinality of the continuation block and
                            sends #whenResolved: appropriately, for
                            future evaluation.</p>
                          <blockquote>
                            <p>Object>>#<<* continuation<br/>
                              <br/>
                              (continuation numArgs == 1)<br/>
                              ifTrue: [^ self whenResolved: [:result |
                              result do: [:each | continuation value:
                              each]]].<br/>
                              ^ self whenResolved: [:result |
                              continuation valueWithArguments: result].</p>
                          </blockquote>
                          <p>One can see a 1 cardinality schedules the
                            continuation to evaluate with each result,
                            while a continuation with cardinality 2 or
                            more will be scheduled to receive all
                            results. #valueWithArguments:</p>
                          <p>Here are 2 return handlers, <br/>
                          </p>
                          <blockquote>
                            <p>promise := ((pair := self
                              promiseResolverPair) key xgcd: 9).</p>
                          </blockquote>
                          <p>the first for each argument <br/>
                          </p>
                          <blockquote>
                            <p>promise <<* [:each | selectCount :=
                              selectCount + 1. Transcript cr; show:
                              'each = ', each];</p>
                          </blockquote>
                          <p>and the second for all three arguments.</p>
                          <blockquote>
                            <p>promise <<* [:g :s :t | unionFlag
                              := true. Transcript cr; show: 'g = ', g,
                              '; s = ', s, '; t = ', t. g + s + t].</p>
                          </blockquote>
                          <pre cols="72" class="moz-signature">--
❤️‍🔥🐰



</pre>
                          <div class="moz-cite-prefix">On 6/21/23 09:44,
                            Luciano Notarfrancesco via Cuis-dev wrote:<br/>
                          </div>
                          <blockquote type="cite">
                            <div dir="auto">Interesting, thanks for
                              sharing!</div>
                            <div dir="auto">Actually I think it’s the
                              same thing I did, my implementation calls
BlockClosure>>#valueWithPossibleArgs: and takes only as many
                              arguments as needed by the block but the
                              array can be bigger than that (it should
                              be named #valueWithPossibleArguments: tho,
                              abbreviations are ugly).</div>
                            <div dir="auto"><br/>
                            </div>
                            <div><br/>
                              <div class="gmail_quote">
                                <div class="gmail_attr" dir="ltr">On
                                  Wed, 21 Jun 2023 at 15:37 Christian
                                  Haider via Cuis-dev <<a class="moz-txt-link-freetext" href="mailto:cuis-dev@lists.cuis.st" moz-do-not-send="true">cuis-dev@lists.cuis.st</a>>
                                  wrote:<br/>
                                </div>
                                <blockquote style="margin: 0px 0px 0px
                                  0.8ex; border-left: 1px solid rgb(204,
                                  204, 204); padding-left: 1ex;" class="gmail_quote">
                                  <div style="" lang="DE">
                                    <div class="m_-976565113171439616WordSection1">
                                      <p class="MsoNormal"><span lang="EN-CA">I added something
                                          similar to my Values package
                                          (VW and ports).</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">The source is</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA">SequenceableCollection>>asArgumentsIn:
                                          aBlock</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> "Evaluate aBlock
                                          with the receiver's elements
                                          as parameters.</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> aBlock takes its
                                          arguments from the receiver.</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> 'ok'</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> #(1 2 3)
                                          asArgumentsIn: [:a :b :c | a +
                                          b + c]</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> #(1 2 3)
                                          asArgumentsIn: [:a :b | a + b]</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> #(1 2 3)
                                          asArgumentsIn: [:a | a]</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> #(1 2 3)
                                          asArgumentsIn: [42]</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> 'not ok'</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> #(1 2 3)
                                          asArgumentsIn: [:a :b :c :d |
                                          a + b + c + d]</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> "</span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> </span></p>
                                      <p style="margin-left: 35.4pt;" class="MsoNormal"><span style="font-family:
                                          "Courier New";" lang="EN-CA"> ^aBlock
                                          cullWithArguments: self
                                          asArray</span><span lang="EN-CA"></span></p>
                                      <p class="MsoNormal"><span lang="EN-CA"> </span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">The difference is
                                          that it takes a list of any
                                          size and picks out the first
                                          items and binds them to the
                                          variables.</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">I use it often
                                          for CSV processing like</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA"> </span><span style="" lang="EN-CA">(line
                                          tokensBasedOn: $;)
                                          asArgumentsIn: [:first :second
                                          :y | … ].</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA"> </span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">I am just a bit
                                          unhappy with the name – it is
                                          too long. It reads ok though.</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">The pipe
                                          character is an interesting
                                          idea. I have to think about
                                          it.</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA"> </span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">I am use it for a
                                          while now and I am very happy
                                          with it.</span></p>
                                      <p class="MsoNormal"><span lang="EN-CA"> </span></p>
                                      <p class="MsoNormal"><span lang="EN-CA">Happy hacking,</span></p>
                                      <p class="MsoNormal"><span>Christian</span></p>
                                    </div>
                                  </div>
                                  <div style="" lang="DE">
                                    <div class="m_-976565113171439616WordSection1">
                                      <p class="MsoNormal"><span> </span></p>
                                      <p class="MsoNormal"><span> </span></p>
                                      <div style="border-width: 1pt
                                        medium medium; border-style:
                                        solid none none; padding: 3pt
                                        0cm 0cm; border-color: rgb(225,
                                        225, 225) currentcolor
                                        currentcolor;">
                                        <p class="MsoNormal"><b>Von:</b>
                                          Cuis-dev <<a class="moz-txt-link-freetext" target="_blank" href="mailto:cuis-dev-bounces@lists.cuis.st" moz-do-not-send="true">cuis-dev-bounces@lists.cuis.st</a>>
                                          <b>Im Auftrag von </b>Luciano
                                          Notarfrancesco via Cuis-dev<br/>
                                          <b>Gesendet:</b> Mittwoch, 21.
                                          Juni 2023 15:13<br/>
                                          <b>An:</b> Discussion of Cuis
                                          Smalltalk <<a class="moz-txt-link-freetext" target="_blank" href="mailto:cuis-dev@lists.cuis.st" moz-do-not-send="true">cuis-dev@lists.cuis.st</a>><br/>
                                          <b>Cc:</b> Luciano
                                          Notarfrancesco <<a class="moz-txt-link-freetext" target="_blank" href="mailto:luchiano@gmail.com" moz-do-not-send="true">luchiano@gmail.com</a>><br/>
                                          <b>Betreff:</b> [Cuis-dev]
                                          Methods that return multiple
                                          values</p>
                                      </div>
                                      <p class="MsoNormal"> </p>
                                      <p class="MsoNormal">Smalltalk
                                        doesn’t have a convention for
                                        methods returning multiple
                                        values, and I’m not aware of any
                                        implementation.</p>
                                      <div>
                                        <p class="MsoNormal">An example
                                          of such thing is the extended
                                          gcd: ‘a xgcd: b’ returns g, s,
                                          t where g is the gcd, and as +
                                          bt = g. Writing methods that
                                          return multiple values is easy
                                          with the curly brackets
                                          syntax, Integer>>#xgcd:
                                          ends with something like</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> ^ {g. s.
                                          t}</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal">But using
                                          sending messages that return
                                          multiple values is kind of
                                          annoying, I end up doing
                                          something like:</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> xgcd := a
                                          xgcd: b.</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> g := xgcd
                                          at: 1.</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> s := xgcd
                                          at: 2.</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> t := xgcd
                                          at: 3</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal">Some years
                                          ago I thought about using
                                          blocks for this, but I never
                                          tried it. Today I just did a
                                          little experiment implementing
                                          anArray | aBlock as ‘^ aBlock
                                          valueWithPossibleArgs: self’
                                          and I can do:</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> (a xgcd:
                                          b) | [:g :s :t| … ]</p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal"> </p>
                                      </div>
                                      <div>
                                        <p class="MsoNormal">This is
                                          seems quite nice already, I
                                          guess I’ll start using it and
                                          see how it feels. But the
                                          point of this mail is not to
                                          show a solution, but to ask if
                                          anyone have thought about this
                                          or if they know any nicer
                                          solutions. Any ideas?</p>
                                      </div>
                                    </div>
                                  </div>
                                  -- <br/>
                                  Cuis-dev mailing list<br/>
                                  <a class="moz-txt-link-freetext" target="_blank" href="mailto:Cuis-dev@lists.cuis.st" moz-do-not-send="true">Cuis-dev@lists.cuis.st</a><br/>
                                  <a class="moz-txt-link-freetext" target="_blank" rel="noreferrer" href="https://lists.cuis.st/mailman/listinfo/cuis-dev" moz-do-not-send="true">https://lists.cuis.st/mailman/listinfo/cuis-dev</a><br/>
                                </blockquote>
                              </div>
                            </div>
                          </blockquote>
                        </blockquote>
                        <pre cols="72" class="moz-signature">--
❤️‍🔥🐰</pre>
                      </blockquote>
                      <br/>
                      <br/>
                      <pre cols="72" class="moz-signature">--
Juan Vuletich
cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
linkedin.com/in/juan-vuletich-75611b3
twitter.com/JuanVuletich</pre>
                    </blockquote>
                  </blockquote>
                  <pre cols="72" class="moz-signature">--
❤️‍🔥🐰</pre>
                </blockquote>
                <br/>
                <br/>
                <pre cols="72" class="moz-signature">--
Juan Vuletich
cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
linkedin.com/in/juan-vuletich-75611b3
twitter.com/JuanVuletich</pre>
              </blockquote>
            </blockquote>
            <br/>
            <br/>
            <pre cols="72" class="moz-signature">--
Juan Vuletich
cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
linkedin.com/in/juan-vuletich-75611b3
twitter.com/JuanVuletich</pre>
          </blockquote>
        </div>
      </div>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
❤️‍🔥🐰</pre>
  
</body></html>