From cc7697baae812850b0b9262bc1b3cb303c6a2adf Mon Sep 17 00:00:00 2001 From: "Luke T. Shumaker" Date: Thu, 17 Apr 2025 12:22:35 -0600 Subject: tests: Name coroutines foo_cr, not cr_foo This makes debugging failing tests easier because gdb-helpers/libcr.py assumes that anything starting with cr_* is internal to libcr. --- libcr_ipc/tests/test_chan.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'libcr_ipc/tests/test_chan.c') diff --git a/libcr_ipc/tests/test_chan.c b/libcr_ipc/tests/test_chan.c index e5d9dc8..4788dd4 100644 --- a/libcr_ipc/tests/test_chan.c +++ b/libcr_ipc/tests/test_chan.c @@ -11,7 +11,7 @@ CR_CHAN_DECLARE(intchan, int); -COROUTINE cr_producer(void *_ch) { +COROUTINE producer_cr(void *_ch) { intchan_t *ch = _ch; cr_begin(); @@ -26,7 +26,7 @@ COROUTINE cr_producer(void *_ch) { cr_end(); } -COROUTINE cr_consumer(void *_ch) { +COROUTINE consumer_cr(void *_ch) { int x; intchan_t *ch = _ch; cr_begin(); @@ -42,8 +42,8 @@ COROUTINE cr_consumer(void *_ch) { int main() { intchan_t ch = {0}; - coroutine_add("producer", cr_producer, &ch); - coroutine_add("consumer", cr_consumer, &ch); + coroutine_add("producer", producer_cr, &ch); + coroutine_add("consumer", consumer_cr, &ch); coroutine_main(); return 0; } -- cgit v1.2.3-2-g168b