summaryrefslogtreecommitdiff
path: root/src/wasm-type-printing.h
diff options
context:
space:
mode:
authorThomas Lively <tlively@google.com>2023-01-18 11:02:33 -0600
committerGitHub <noreply@github.com>2023-01-18 09:02:33 -0800
commitab5b3e455770fec0e9ac78e566b48ec5a873a7ca (patch)
tree7081c51f7dd3acadb4725651ed9e0bef350b01e1 /src/wasm-type-printing.h
parenteedb2fe5e37174acba69e84e8bb9ee2628e0d7f3 (diff)
downloadbinaryen-ab5b3e455770fec0e9ac78e566b48ec5a873a7ca.tar.gz
binaryen-ab5b3e455770fec0e9ac78e566b48ec5a873a7ca.tar.bz2
binaryen-ab5b3e455770fec0e9ac78e566b48ec5a873a7ca.zip
Factor supertype-first type sort into separate header (#5436)
type-updating.cpp implemented a topological sorts on heap types that would visit supertypes first. Since this same sort will be used by TypeMerging.cpp in #5432, factor it out into a shared utility in a new wasm-type-ordering.h header. At the same time, fix a bug in which the sort would visit types not in the input collection. Concretely, this bug would cause public supertypes of private types to be visited when only private types should have been visited. This functionality change will be tested in #5432. In principle the subtype-first sort used in subtypes.h could also be moved to this header, but that is not yet duplicated in the code base and is more efficient because it depends on implementation details of its current context, so do not move it for now.
Diffstat (limited to 'src/wasm-type-printing.h')
0 files changed, 0 insertions, 0 deletions