summaryrefslogtreecommitdiff
path: root/src/tools/wasm-reduce.cpp
diff options
context:
space:
mode:
authorThomas Lively <7121787+tlively@users.noreply.github.com>2022-02-03 15:11:47 -0800
committerGitHub <noreply@github.com>2022-02-03 23:11:47 +0000
commit22cf8e143a435fec8b4a6bf75adb673e1f5c9dae (patch)
tree349c22318383d368f7a4b08b04ca1bc52ed15eeb /src/tools/wasm-reduce.cpp
parent880c765ab9a4124f708da57329dcbe07c1ca9fa3 (diff)
downloadbinaryen-22cf8e143a435fec8b4a6bf75adb673e1f5c9dae.tar.gz
binaryen-22cf8e143a435fec8b4a6bf75adb673e1f5c9dae.tar.bz2
binaryen-22cf8e143a435fec8b4a6bf75adb673e1f5c9dae.zip
CRTP topological sort utility (#4499)
Refactor the `TopologicalSortStack` into a `TopologicalSort` CRTP utility that manipulates the DFS stack internally instead of exposing it to the user. The only method users have to implement to use the utility is `pushPredecessors`, which should call the provided `push` method on all the predecessors of a given item. The public interface to `TopologicalSort` is an input iterator, so it can easily be used in range-based for loops.
Diffstat (limited to 'src/tools/wasm-reduce.cpp')
0 files changed, 0 insertions, 0 deletions