summaryrefslogtreecommitdiff
path: root/test/example/c-api-kitchen-sink.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/example/c-api-kitchen-sink.c')
-rw-r--r--test/example/c-api-kitchen-sink.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/example/c-api-kitchen-sink.c b/test/example/c-api-kitchen-sink.c
index 5935e9993..b2218993c 100644
--- a/test/example/c-api-kitchen-sink.c
+++ b/test/example/c-api-kitchen-sink.c
@@ -427,6 +427,9 @@ void test_relooper() {
RelooperRef relooper = RelooperCreate();
BinaryenExpressionRef temp = makeInt32(module, -99);
RelooperBlockRef block0 = RelooperAddBlockWithSwitch(relooper, makeCallCheck(module, 0), temp);
+ // TODO: this example is not very good, the blocks should end in a |return| as otherwise they
+ // fall through to each other. A relooper block should end in something that stops control
+ // flow, if it doesn't have branches going out
RelooperBlockRef block1 = RelooperAddBlock(relooper, makeCallCheck(module, 1));
RelooperBlockRef block2 = RelooperAddBlock(relooper, makeCallCheck(module, 2));
RelooperBlockRef block3 = RelooperAddBlock(relooper, makeCallCheck(module, 3));