2
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@mcc" class="u-url mention">@<span>mcc</span></a></span> block example: <a href="https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/Control_flow/block" target="_blank" rel="nofollow noopener" translate="no"><span class="invisible">https://</span><span class="ellipsis">developer.mozilla.org/en-US/do</span><span class="invisible">cs/WebAssembly/Reference/Control_flow/block</span></a></p><p>querying stack depth: no, you&#39;re not allowed to do anything that would make stack depth dynamic, therefore there is no need to have an operation to query it</p>
<p>networking folks: the minimum Ethernet frame size is 64 octets, right? does that include the FCS?</p>
<p>By the way if anyone has an easy way to point me to any of the following it would be much appreciated</p><p>- An example of the (block) syntax in textual wasm<br />- An &quot;alignment&quot; is described in &quot;memarg&quot; in the spec, but this shows up nowhere in the textual wasm examples I find. Is this implicit in the use of `i32.` instructions?<br />- Is there a way to query the current wasm stack depth?</p>
<p>OK so</p><p>I&#39;m struggling with this week due to many issues that feel to me artificial. I don&#39;t like how this spec is written. I don&#39;t like a lot of the decisions</p><p>Buuut *sigh*</p><p>I guess I got the Good Idea out of the wasm spec I was hoping to find when I picked it. I was feeling like this S-expression form didn&#39;t &quot;feel like&quot; a LISP. And then I found this bit in the PDF spec. Using a syntax reordering trick to represent a Forth in LISP style. That&#39;s *saying this as if miserable* really smart actually</p>
Attached image 0
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@mcc" class="u-url mention">@<span>mcc</span></a></span> this is the simplest thing you can do to accomplish this task in plain wasm, yes</p>
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@whitequark" class="u-url mention">@<span>whitequark</span></a></span> all right. if i&#39;m trying to implement &quot;putc&quot; by pulling fd_write out of preview1 and telling it to print a single char from a single iov , am I to your knowledge missing a simpler method?</p>
<p><span class="h-card" translate="no"><a href="https://frankwiles.social/@frank" class="u-url mention">@<span>frank</span></a></span> <span class="h-card" translate="no"><a href="https://mastodon.social/@dabeaz" class="u-url mention">@<span>dabeaz</span></a></span> i did it already and have forgotten what it was</p>
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@mcc" class="u-url mention">@<span>mcc</span></a></span> the functions in preview1 were chosen based on something called &quot;cloudlibc&quot; / &quot;cloudabi&quot;</p>
<p><span class="h-card" translate="no"><a href="https://mastodon.social/@dabeaz" class="u-url mention">@<span>dabeaz</span></a></span> its a metaphor, kid. The guy is from mit. Probably doesn’t even know how to make a fist</p>