From e831a9d51b687d5f5151453141d528b63a9be5af Mon Sep 17 00:00:00 2001 From: Cas Cremers Date: Fri, 19 Oct 2018 15:51:47 -0400 Subject: [PATCH] Another simple trampoline removed. --- src/compiler.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/compiler.c b/src/compiler.c index adebaa1..20d358f 100644 --- a/src/compiler.c +++ b/src/compiler.c @@ -2332,16 +2332,19 @@ void checkWellFormed (const System sys) { int allOkay; + Protocol p; allOkay = true; + for (p = sys->protocols; p != NULL; p = p->next) + { + Role r; - int thisRole (Protocol p, Role r) - { - allOkay = allOkay && WellFormedRole (sys, p, r); - return true; - } + for (r = p->roles; r != NULL; r = r->next) + { + allOkay = allOkay && WellFormedRole (sys, p, r); + } + } - iterateRoles (sys, thisRole); if (allOkay == false) { error