From 6a7dd2787ad3ee11a460ff81fab5adca9799dc8f Mon Sep 17 00:00:00 2001 From: Matt Pharr Date: Wed, 21 Mar 2012 10:06:53 -0700 Subject: [PATCH] Fix bug in check for varying parameters in exported functions. In particular, we weren't checking to see if the pointed-to type of pointer parameters was varying. Fixes issue #191. --- module.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/module.cpp b/module.cpp index 1539347e..99da37ab 100644 --- a/module.cpp +++ b/module.cpp @@ -356,8 +356,11 @@ lRecursiveCheckValidParamType(const Type *t) { return lRecursiveCheckValidParamType(seqt->GetElementType()); const PointerType *pt = dynamic_cast(t); - if (pt != NULL) - return (pt->IsSlice() || pt->IsVaryingType()); + if (pt != NULL) { + if (pt->IsSlice() || pt->IsVaryingType()) + return true; + return lRecursiveCheckValidParamType(pt->GetBaseType()); + } return t->IsVaryingType(); }