Add documentation to BinaryenIf
Adds a comment to explain that a (result) is only added to BinaryenIf statements if both arms return concrete types.
Relates to https://github.com/WebAssembly/binaryen/issues/6868
Thanks for the PR!
I'm not sure where the best place to put this documentation is. We should perhaps point to wasm-builder.h or wasm.cpp as containing the implementations of the expression constructors. That is, I'm not sure if it's worth duplicating such docs into the C API, though at the same, the wasm-builder.h/wasm.cpp code is more code and not documentation, so maybe we need a new place for it..?
@kripken I'm happy to move it wherever you'd like! I put it in the header file for the binaryen api directly as I see that as the point of interface for most people who are using the binaryen api -- but I could be wrong. That is, as I've been building my application using Binaryen, I've been referring to the header file as the "source of truth" for how things work.
It may be more tedious / less discoverable if it is moved into the source of the implementation itself