From 8e65f3539cca89375e73eb6aad9959dbe4485583 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Thu, 25 May 2017 06:37:50 -0700 Subject: ffi: don't compile struct member type twice. * ffi.c (ffi_struct_compile): Eliminate redundant call to ffi_type_compile, replacing it with the compiled type we already have. --- ffi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ffi.c') diff --git a/ffi.c b/ffi.c index e7ee8ed4..6e71e743 100644 --- a/ffi.c +++ b/ffi.c @@ -1636,7 +1636,7 @@ static val ffi_struct_compile(val membs, val *ptypes, val self) if (ctft->size == 0) uw_throwf(error_s, lit("~a: incomplete type ~s cannot be struct member"), self, type, nao); - pttail = list_collect(pttail, ffi_type_compile(type)); + pttail = list_collect(pttail, comp_type); pstail = list_collect(pstail, name); } -- cgit v1.2.3