<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body><div style="font-family: sans-serif;"><div class="markdown" style="white-space: normal;">
<p dir="auto">I’m very glad to see this moving towards completion.<br>
Better threads richly deserve better thread locals!</p>
<p dir="auto">I’d like to check my understanding of the intermediate<br>
type <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">Carrier</code>.  Is it the case that the information content<br>
of a carrier made by <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c=ExtentLocal.where(k,v)</code> is just exactly<br>
the pair <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">k,v</code>?  And then, after that, I suppose a carrier made<br>
by <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c.where(k2,v2)</code> contains exactly <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">k,v,k2,v2</code>.  (But if<br>
<code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">k==k2</code> then the information content is just <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">k2,v2</code>.)</p>
<p dir="auto">And if that is true, then I can store a <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">Carrier</code> in a global<br>
variable, even pass it to five other threads, and have each<br>
of them call <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c.run(…)</code> with completely independent sets of<br>
bindings, except for the <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">k,v,k2,v2</code> mandated by the carrier’s<br>
information content.</p>
<p dir="auto">What I’m trying to exclude here is that a <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">Carrier</code> somehow<br>
threads in the ambient binding map for the current extent,<br>
as non-locally defined by all of the caller frames, plus<br>
whatever bindings might have been provided when the current<br>
thread was launched.</p>
<p dir="auto">IIRC you have chosen not to provide general methods for working<br>
with binding maps.  (There is no key/value iterator on <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">Carrier</code>.)<br>
And then reifying the very special binding map in the current<br>
extent is right out.  I think this is fine, although maybe use<br>
cases will eventually call for map-like views on both local<br>
carrier multi-tuples and grand non-local binding maps.  Those<br>
can be added later if needed.</p>
<p dir="auto">So, my asking to confirm the very finite and local information<br>
content of the type <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">Carrier</code> is really me double-checking<br>
that no larger binding-map API sneaks through the current JEP<br>
API.</p>
<p dir="auto">A very different design would sneak in an reified map pointer<br>
into every result of <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c=ExtentLocal.where(k,v)</code> such that<br>
bindings available in <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c.run(…)</code> would come only from c<br>
and its uplevel pointer, completely blocking any bindings<br>
present at the call to <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c.run</code>.  I guess such bindings would<br>
no longer be properly called “extent-local”; only the binding<br>
map root would be extent local but it would be subject to<br>
radical editing on each call to <code style="margin: 0; padding: 0 0.4em; border-radius: 3px; background-color: #F7F7F7;">c.run(…)</code>.</p>
<p dir="auto">Make sense?</p>

</div></div></body>

</html>