Handle same-instance stream/future writes when element is empty#508
Handle same-instance stream/future writes when element is empty#508lukewagner merged 1 commit intomainfrom
Conversation
|
Trying to actually test this, I just noticed that #440 forgot to update Binary.md to provide an encoding for the "none" case in all the stream/future built-ins (they currently unconditionally take a In the type section, which was updated, the Based on this, what I think the fix is here is to keep the binary format taking a WDYT? |
|
I think the prototyping repo already implements the behavior you describe where the typeidx is required to be a |
|
Sweet; that looks great. I expect it matched spec before the spec changed. I'll file a new PR to switch back. |
7d3f2e7 to
47a6b2b
Compare
As discussed in #475, as a temporary expediency, the CABI currently traps when trying to lift and lower in the same component instance to avoid the otherwise subtle ordering issues that arise with memory aliasing. However, if the element type is empty (as enabled by #440), there is no such memory aliasing issue. Moreover, such futures/streams can be used as a simple way to support #459 use cases without having to add anything fancier like the
wait-asyncbuilt-in suggested in #459. Thus, this tiny PR loosens the same-instance trapping condition to only trap if there is a non-empty element type.